├── .clang-format ├── .gitignore ├── CMakeLists.txt ├── LICENSE ├── README.md ├── config ├── 1843_low_cfar_last.cfg └── config.yaml ├── external ├── munkres-algorithm │ ├── .gitignore │ ├── LICENSE │ ├── Makefile │ ├── README.md │ ├── catch.hpp │ ├── example.cpp │ ├── munkres.hpp │ └── test.cpp └── yaml-cpp │ ├── .clang-format │ ├── .codedocs │ ├── .github │ └── workflows │ │ └── build.yml │ ├── .gitignore │ ├── .travis.yml │ ├── BUILD.bazel │ ├── CMakeLists.txt │ ├── CONTRIBUTING.md │ ├── LICENSE │ ├── README.md │ ├── WORKSPACE │ ├── appveyor.yml │ ├── docs │ ├── Breaking-Changes.md │ ├── How-To-Emit-YAML.md │ ├── How-To-Parse-A-Document-(Old-API).md │ ├── Strings.md │ ├── Tutorial.md │ ├── _config.yml │ └── index.md │ ├── include │ └── yaml-cpp │ │ ├── anchor.h │ │ ├── binary.h │ │ ├── contrib │ │ ├── anchordict.h │ │ └── graphbuilder.h │ │ ├── depthguard.h │ │ ├── dll.h │ │ ├── emitfromevents.h │ │ ├── emitter.h │ │ ├── emitterdef.h │ │ ├── emittermanip.h │ │ ├── emitterstyle.h │ │ ├── eventhandler.h │ │ ├── exceptions.h │ │ ├── mark.h │ │ ├── node │ │ ├── convert.h │ │ ├── detail │ │ │ ├── impl.h │ │ │ ├── iterator.h │ │ │ ├── iterator_fwd.h │ │ │ ├── memory.h │ │ │ ├── node.h │ │ │ ├── node_data.h │ │ │ ├── node_iterator.h │ │ │ └── node_ref.h │ │ ├── emit.h │ │ ├── impl.h │ │ ├── iterator.h │ │ ├── node.h │ │ ├── parse.h │ │ ├── ptr.h │ │ └── type.h │ │ ├── noexcept.h │ │ ├── null.h │ │ ├── ostream_wrapper.h │ │ ├── parser.h │ │ ├── stlemitter.h │ │ ├── traits.h │ │ └── yaml.h │ ├── install.txt │ ├── src │ ├── binary.cpp │ ├── collectionstack.h │ ├── contrib │ │ ├── graphbuilder.cpp │ │ ├── graphbuilderadapter.cpp │ │ ├── graphbuilderadapter.h │ │ ├── yaml-cpp.natvis │ │ └── yaml-cpp.natvis.md │ ├── convert.cpp │ ├── depthguard.cpp │ ├── directives.cpp │ ├── directives.h │ ├── emit.cpp │ ├── emitfromevents.cpp │ ├── emitter.cpp │ ├── emitterstate.cpp │ ├── emitterstate.h │ ├── emitterutils.cpp │ ├── emitterutils.h │ ├── exceptions.cpp │ ├── exp.cpp │ ├── exp.h │ ├── indentation.h │ ├── memory.cpp │ ├── node.cpp │ ├── node_data.cpp │ ├── nodebuilder.cpp │ ├── nodebuilder.h │ ├── nodeevents.cpp │ ├── nodeevents.h │ ├── null.cpp │ ├── ostream_wrapper.cpp │ ├── parse.cpp │ ├── parser.cpp │ ├── ptr_vector.h │ ├── regex_yaml.cpp │ ├── regex_yaml.h │ ├── regeximpl.h │ ├── scanner.cpp │ ├── scanner.h │ ├── scanscalar.cpp │ ├── scanscalar.h │ ├── scantag.cpp │ ├── scantag.h │ ├── scantoken.cpp │ ├── setting.h │ ├── simplekey.cpp │ ├── singledocparser.cpp │ ├── singledocparser.h │ ├── stream.cpp │ ├── stream.h │ ├── streamcharsource.h │ ├── stringsource.h │ ├── tag.cpp │ ├── tag.h │ └── token.h │ ├── test │ ├── BUILD.bazel │ ├── CMakeLists.txt │ ├── binary_test.cpp │ ├── create-emitter-tests.py │ ├── gtest-1.10.0 │ │ ├── .clang-format │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── BUILD.bazel │ │ ├── CMakeLists.txt │ │ ├── CONTRIBUTING.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── WORKSPACE │ │ ├── appveyor.yml │ │ ├── ci │ │ │ ├── build-linux-bazel.sh │ │ │ ├── build-platformio.sh │ │ │ ├── env-linux.sh │ │ │ ├── env-osx.sh │ │ │ ├── get-nprocessors.sh │ │ │ ├── install-linux.sh │ │ │ ├── install-osx.sh │ │ │ ├── install-platformio.sh │ │ │ ├── log-config.sh │ │ │ └── travis.sh │ │ ├── googlemock │ │ │ ├── CMakeLists.txt │ │ │ ├── CONTRIBUTORS │ │ │ ├── LICENSE │ │ │ ├── README.md │ │ │ ├── cmake │ │ │ │ ├── gmock.pc.in │ │ │ │ └── gmock_main.pc.in │ │ │ ├── docs │ │ │ │ ├── cheat_sheet.md │ │ │ │ ├── cook_book.md │ │ │ │ ├── for_dummies.md │ │ │ │ └── gmock_faq.md │ │ │ ├── include │ │ │ │ └── gmock │ │ │ │ │ ├── gmock-actions.h │ │ │ │ │ ├── gmock-cardinalities.h │ │ │ │ │ ├── gmock-function-mocker.h │ │ │ │ │ ├── gmock-generated-actions.h │ │ │ │ │ ├── gmock-generated-actions.h.pump │ │ │ │ │ ├── gmock-generated-function-mockers.h │ │ │ │ │ ├── gmock-generated-function-mockers.h.pump │ │ │ │ │ ├── gmock-generated-matchers.h │ │ │ │ │ ├── gmock-generated-matchers.h.pump │ │ │ │ │ ├── gmock-matchers.h │ │ │ │ │ ├── gmock-more-actions.h │ │ │ │ │ ├── gmock-more-matchers.h │ │ │ │ │ ├── gmock-nice-strict.h │ │ │ │ │ ├── gmock-spec-builders.h │ │ │ │ │ ├── gmock.h │ │ │ │ │ └── internal │ │ │ │ │ ├── custom │ │ │ │ │ ├── README.md │ │ │ │ │ ├── gmock-generated-actions.h │ │ │ │ │ ├── gmock-generated-actions.h.pump │ │ │ │ │ ├── gmock-matchers.h │ │ │ │ │ └── gmock-port.h │ │ │ │ │ ├── gmock-internal-utils.h │ │ │ │ │ ├── gmock-port.h │ │ │ │ │ └── gmock-pp.h │ │ │ ├── scripts │ │ │ │ ├── fuse_gmock_files.py │ │ │ │ ├── generator │ │ │ │ │ ├── LICENSE │ │ │ │ │ ├── README │ │ │ │ │ ├── README.cppclean │ │ │ │ │ ├── cpp │ │ │ │ │ │ ├── __init__.py │ │ │ │ │ │ ├── ast.py │ │ │ │ │ │ ├── gmock_class.py │ │ │ │ │ │ ├── gmock_class_test.py │ │ │ │ │ │ ├── keywords.py │ │ │ │ │ │ ├── tokenize.py │ │ │ │ │ │ └── utils.py │ │ │ │ │ └── gmock_gen.py │ │ │ │ ├── gmock-config.in │ │ │ │ ├── gmock_doctor.py │ │ │ │ ├── upload.py │ │ │ │ └── upload_gmock.py │ │ │ ├── src │ │ │ │ ├── gmock-all.cc │ │ │ │ ├── gmock-cardinalities.cc │ │ │ │ ├── gmock-internal-utils.cc │ │ │ │ ├── gmock-matchers.cc │ │ │ │ ├── gmock-spec-builders.cc │ │ │ │ ├── gmock.cc │ │ │ │ └── gmock_main.cc │ │ │ └── test │ │ │ │ ├── BUILD.bazel │ │ │ │ ├── gmock-actions_test.cc │ │ │ │ ├── gmock-cardinalities_test.cc │ │ │ │ ├── gmock-function-mocker_nc.cc │ │ │ │ ├── gmock-function-mocker_nc_test.py │ │ │ │ ├── gmock-function-mocker_test.cc │ │ │ │ ├── gmock-generated-actions_test.cc │ │ │ │ ├── gmock-generated-function-mockers_test.cc │ │ │ │ ├── gmock-generated-matchers_test.cc │ │ │ │ ├── gmock-internal-utils_test.cc │ │ │ │ ├── gmock-matchers_test.cc │ │ │ │ ├── gmock-more-actions_test.cc │ │ │ │ ├── gmock-nice-strict_test.cc │ │ │ │ ├── gmock-port_test.cc │ │ │ │ ├── gmock-pp-string_test.cc │ │ │ │ ├── gmock-pp_test.cc │ │ │ │ ├── gmock-spec-builders_test.cc │ │ │ │ ├── gmock_all_test.cc │ │ │ │ ├── gmock_ex_test.cc │ │ │ │ ├── gmock_leak_test.py │ │ │ │ ├── gmock_leak_test_.cc │ │ │ │ ├── gmock_link2_test.cc │ │ │ │ ├── gmock_link_test.cc │ │ │ │ ├── gmock_link_test.h │ │ │ │ ├── gmock_output_test.py │ │ │ │ ├── gmock_output_test_.cc │ │ │ │ ├── gmock_output_test_golden.txt │ │ │ │ ├── gmock_stress_test.cc │ │ │ │ ├── gmock_test.cc │ │ │ │ └── gmock_test_utils.py │ │ ├── googletest │ │ │ ├── CMakeLists.txt │ │ │ ├── CONTRIBUTORS │ │ │ ├── LICENSE │ │ │ ├── README.md │ │ │ ├── cmake │ │ │ │ ├── Config.cmake.in │ │ │ │ ├── gtest.pc.in │ │ │ │ ├── gtest_main.pc.in │ │ │ │ ├── internal_utils.cmake │ │ │ │ └── libgtest.la.in │ │ │ ├── docs │ │ │ │ ├── advanced.md │ │ │ │ ├── faq.md │ │ │ │ ├── pkgconfig.md │ │ │ │ ├── primer.md │ │ │ │ ├── pump_manual.md │ │ │ │ └── samples.md │ │ │ ├── include │ │ │ │ └── gtest │ │ │ │ │ ├── gtest-death-test.h │ │ │ │ │ ├── gtest-matchers.h │ │ │ │ │ ├── gtest-message.h │ │ │ │ │ ├── gtest-param-test.h │ │ │ │ │ ├── gtest-printers.h │ │ │ │ │ ├── gtest-spi.h │ │ │ │ │ ├── gtest-test-part.h │ │ │ │ │ ├── gtest-typed-test.h │ │ │ │ │ ├── gtest.h │ │ │ │ │ ├── gtest_pred_impl.h │ │ │ │ │ ├── gtest_prod.h │ │ │ │ │ └── internal │ │ │ │ │ ├── custom │ │ │ │ │ ├── README.md │ │ │ │ │ ├── gtest-port.h │ │ │ │ │ ├── gtest-printers.h │ │ │ │ │ └── gtest.h │ │ │ │ │ ├── gtest-death-test-internal.h │ │ │ │ │ ├── gtest-filepath.h │ │ │ │ │ ├── gtest-internal.h │ │ │ │ │ ├── gtest-param-util.h │ │ │ │ │ ├── gtest-port-arch.h │ │ │ │ │ ├── gtest-port.h │ │ │ │ │ ├── gtest-string.h │ │ │ │ │ ├── gtest-type-util.h │ │ │ │ │ └── gtest-type-util.h.pump │ │ │ ├── samples │ │ │ │ ├── prime_tables.h │ │ │ │ ├── sample1.cc │ │ │ │ ├── sample1.h │ │ │ │ ├── sample10_unittest.cc │ │ │ │ ├── sample1_unittest.cc │ │ │ │ ├── sample2.cc │ │ │ │ ├── sample2.h │ │ │ │ ├── sample2_unittest.cc │ │ │ │ ├── sample3-inl.h │ │ │ │ ├── sample3_unittest.cc │ │ │ │ ├── sample4.cc │ │ │ │ ├── sample4.h │ │ │ │ ├── sample4_unittest.cc │ │ │ │ ├── sample5_unittest.cc │ │ │ │ ├── sample6_unittest.cc │ │ │ │ ├── sample7_unittest.cc │ │ │ │ ├── sample8_unittest.cc │ │ │ │ └── sample9_unittest.cc │ │ │ ├── scripts │ │ │ │ ├── common.py │ │ │ │ ├── fuse_gtest_files.py │ │ │ │ ├── gen_gtest_pred_impl.py │ │ │ │ ├── gtest-config.in │ │ │ │ ├── pump.py │ │ │ │ ├── release_docs.py │ │ │ │ ├── upload.py │ │ │ │ └── upload_gtest.py │ │ │ ├── src │ │ │ │ ├── gtest-all.cc │ │ │ │ ├── gtest-death-test.cc │ │ │ │ ├── gtest-filepath.cc │ │ │ │ ├── gtest-internal-inl.h │ │ │ │ ├── gtest-matchers.cc │ │ │ │ ├── gtest-port.cc │ │ │ │ ├── gtest-printers.cc │ │ │ │ ├── gtest-test-part.cc │ │ │ │ ├── gtest-typed-test.cc │ │ │ │ ├── gtest.cc │ │ │ │ └── gtest_main.cc │ │ │ └── test │ │ │ │ ├── BUILD.bazel │ │ │ │ ├── googletest-break-on-failure-unittest.py │ │ │ │ ├── googletest-break-on-failure-unittest_.cc │ │ │ │ ├── googletest-catch-exceptions-test.py │ │ │ │ ├── googletest-catch-exceptions-test_.cc │ │ │ │ ├── googletest-color-test.py │ │ │ │ ├── googletest-color-test_.cc │ │ │ │ ├── googletest-death-test-test.cc │ │ │ │ ├── googletest-death-test_ex_test.cc │ │ │ │ ├── googletest-env-var-test.py │ │ │ │ ├── googletest-env-var-test_.cc │ │ │ │ ├── googletest-filepath-test.cc │ │ │ │ ├── googletest-filter-unittest.py │ │ │ │ ├── googletest-filter-unittest_.cc │ │ │ │ ├── googletest-json-outfiles-test.py │ │ │ │ ├── googletest-json-output-unittest.py │ │ │ │ ├── googletest-list-tests-unittest.py │ │ │ │ ├── googletest-list-tests-unittest_.cc │ │ │ │ ├── googletest-listener-test.cc │ │ │ │ ├── googletest-message-test.cc │ │ │ │ ├── googletest-options-test.cc │ │ │ │ ├── googletest-output-test-golden-lin.txt │ │ │ │ ├── googletest-output-test.py │ │ │ │ ├── googletest-output-test_.cc │ │ │ │ ├── googletest-param-test-invalid-name1-test.py │ │ │ │ ├── googletest-param-test-invalid-name1-test_.cc │ │ │ │ ├── googletest-param-test-invalid-name2-test.py │ │ │ │ ├── googletest-param-test-invalid-name2-test_.cc │ │ │ │ ├── googletest-param-test-test.cc │ │ │ │ ├── googletest-param-test-test.h │ │ │ │ ├── googletest-param-test2-test.cc │ │ │ │ ├── googletest-port-test.cc │ │ │ │ ├── googletest-printers-test.cc │ │ │ │ ├── googletest-shuffle-test.py │ │ │ │ ├── googletest-shuffle-test_.cc │ │ │ │ ├── googletest-test-part-test.cc │ │ │ │ ├── googletest-test2_test.cc │ │ │ │ ├── googletest-throw-on-failure-test.py │ │ │ │ ├── googletest-throw-on-failure-test_.cc │ │ │ │ ├── googletest-uninitialized-test.py │ │ │ │ ├── googletest-uninitialized-test_.cc │ │ │ │ ├── gtest-typed-test2_test.cc │ │ │ │ ├── gtest-typed-test_test.cc │ │ │ │ ├── gtest-typed-test_test.h │ │ │ │ ├── gtest-unittest-api_test.cc │ │ │ │ ├── gtest_all_test.cc │ │ │ │ ├── gtest_assert_by_exception_test.cc │ │ │ │ ├── gtest_environment_test.cc │ │ │ │ ├── gtest_help_test.py │ │ │ │ ├── gtest_help_test_.cc │ │ │ │ ├── gtest_json_test_utils.py │ │ │ │ ├── gtest_list_output_unittest.py │ │ │ │ ├── gtest_list_output_unittest_.cc │ │ │ │ ├── gtest_main_unittest.cc │ │ │ │ ├── gtest_no_test_unittest.cc │ │ │ │ ├── gtest_pred_impl_unittest.cc │ │ │ │ ├── gtest_premature_exit_test.cc │ │ │ │ ├── gtest_prod_test.cc │ │ │ │ ├── gtest_repeat_test.cc │ │ │ │ ├── gtest_skip_environment_check_output_test.py │ │ │ │ ├── gtest_skip_in_environment_setup_test.cc │ │ │ │ ├── gtest_skip_test.cc │ │ │ │ ├── gtest_sole_header_test.cc │ │ │ │ ├── gtest_stress_test.cc │ │ │ │ ├── gtest_test_macro_stack_footprint_test.cc │ │ │ │ ├── gtest_test_utils.py │ │ │ │ ├── gtest_testbridge_test.py │ │ │ │ ├── gtest_testbridge_test_.cc │ │ │ │ ├── gtest_throw_on_failure_ex_test.cc │ │ │ │ ├── gtest_unittest.cc │ │ │ │ ├── gtest_xml_outfile1_test_.cc │ │ │ │ ├── gtest_xml_outfile2_test_.cc │ │ │ │ ├── gtest_xml_outfiles_test.py │ │ │ │ ├── gtest_xml_output_unittest.py │ │ │ │ ├── gtest_xml_output_unittest_.cc │ │ │ │ ├── gtest_xml_test_utils.py │ │ │ │ ├── production.cc │ │ │ │ └── production.h │ │ ├── library.json │ │ └── platformio.ini │ ├── handler_test.h │ ├── integration │ │ ├── emitter_test.cpp │ │ ├── encoding_test.cpp │ │ ├── error_messages_test.cpp │ │ ├── gen_emitter_test.cpp │ │ ├── handler_spec_test.cpp │ │ ├── handler_test.cpp │ │ ├── load_node_test.cpp │ │ └── node_spec_test.cpp │ ├── main.cpp │ ├── mock_event_handler.h │ ├── node │ │ └── node_test.cpp │ ├── ostream_wrapper_test.cpp │ ├── parser_test.cpp │ ├── regex_test.cpp │ └── specexamples.h │ ├── util │ ├── CMakeLists.txt │ ├── api.cpp │ ├── parse.cpp │ ├── read.cpp │ └── sandbox.cpp │ ├── yaml-cpp-config.cmake.in │ └── yaml-cpp.pc.in ├── include └── aaucns_rio │ ├── calc_q.h │ ├── circular_buffer.h │ ├── config.h │ ├── constants.h │ ├── debug.h │ ├── features.h │ ├── fg │ ├── factors_data.h │ ├── filter_state_factory.h │ ├── imu_measurement.h │ ├── marginalization.h │ ├── pf_distance_factor.h │ ├── radar_distance_factor.h │ ├── radar_velocity_factor.h │ ├── rio_fg.h │ └── rio_fg_replay.h │ ├── id_manager.h │ ├── iteration.h │ ├── parameters.h │ ├── pcl_conversions_rio.h │ ├── points_associator.h │ ├── rio.h │ ├── rio_replay.h │ ├── state.h │ ├── state_predictor.h │ ├── state_updater.h │ ├── timer.h │ ├── trail.h │ ├── trailpoint.h │ ├── util.h │ └── velocity_provider.h ├── launch ├── aaucns_rio.launch ├── aaucns_rio_fg.launch ├── aaucns_rio_fg_replay.launch ├── aaucns_rio_fg_replay_gdb.launch ├── aaucns_rio_gdb.launch ├── aaucns_rio_memcheck.launch ├── aaucns_rio_replay.launch └── aaucns_rio_replay_gdb.launch ├── msg └── DoubleArrayStamped.msg ├── nodes ├── rio_fg_node.cpp ├── rio_fg_replay_node.cpp ├── rio_node.cpp └── rio_replay_node.cpp ├── package.xml └── src ├── constants.cpp ├── fg ├── imu_measurement.cpp ├── marginalization.cpp ├── rio_fg.cpp └── rio_fg_replay.cpp ├── pcl_conversions_rio.cpp ├── points_associator.cpp ├── rio.cpp ├── rio_replay.cpp ├── state.cpp ├── state_predictor.cpp ├── state_updater.cpp └── velocity_provider.cpp /.gitignore: -------------------------------------------------------------------------------- 1 | bags 2 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | BSD 3-Clause License 2 | 3 | Copyright (c) 2024, Control of Networked Systems - University Klagenfurt 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, this 9 | list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its 16 | contributors may be used to endorse or promote products derived from 17 | this software without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 20 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 21 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 22 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 24 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 25 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 26 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 27 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | -------------------------------------------------------------------------------- /config/1843_low_cfar_last.cfg: -------------------------------------------------------------------------------- 1 | % *************************************************************** 2 | % Created for SDK ver:03.05 3 | % Created using Visualizer ver:3.5.0.0 4 | % Frequency:77 5 | % Platform:xWR18xx 6 | % Scene Classifier:best_range_res 7 | % Azimuth Resolution(deg):15 + Elevation 8 | % Range Resolution(m):0.039 9 | % Maximum unambiguous Range(m):16.28 10 | % Maximum Radial Velocity(m/s):1.51 11 | % Radial velocity resolution(m/s):0.1 12 | % Frame Duration(msec):66.667 13 | % RF calibration data:None 14 | % *************************************************************** 15 | sensorStop 16 | flushCfg 17 | dfeDataOutputMode 1 18 | channelCfg 15 7 0 19 | adcCfg 2 1 20 | adcbufCfg -1 0 1 1 1 21 | profileCfg 0 77 55 7 160 0 0 25 1 512 3368 0 0 30 22 | chirpCfg 0 0 0 0 0 0 0 1 23 | chirpCfg 1 1 0 0 0 0 0 4 24 | chirpCfg 2 2 0 0 0 0 0 2 25 | frameCfg 0 2 32 0 66.667 1 0 26 | lowPower 0 0 27 | guiMonitor -1 1 1 0 0 0 1 28 | cfarCfg -1 0 2 8 4 3 0 8 1 29 | cfarCfg -1 1 0 8 4 4 1 10 1 30 | multiObjBeamForming -1 1 0.5 31 | clutterRemoval -1 0 32 | calibDcRangeSig -1 0 -5 8 256 33 | extendedMaxVelocity -1 0 34 | lvdsStreamCfg -1 0 0 0 35 | compRangeBiasAndRxChanPhase 0.0747793 -0.59357 -0.35477 -0.55957 -0.53607 -0.63293 -0.49060 -0.48358 -0.60635 -0.81256 -0.16968 -0.85245 -0.37903 -0.91193 -0.27710 -0.79947 -0.48776 -0.86267 -0.19089 -0.91196 -0.41028 -0.94827 -0.30005 -0.84863 -0.48697 36 | measureRangeBiasAndRxChanPhase 0 1.5 0.2 37 | CQRxSatMonitor 0 3 15 125 0 38 | CQSigImgMonitor 0 127 8 39 | analogMonitor 0 0 40 | aoaFovCfg -1 -90 90 -90 90 41 | cfarFovCfg -1 0 0 16.16 42 | cfarFovCfg -1 1 -1.51 1.51 43 | calibData 0 0 0 44 | sensorStart 45 | -------------------------------------------------------------------------------- /config/config.yaml: -------------------------------------------------------------------------------- 1 | # Initial state. 2 | px: 0 3 | py: 0 4 | pz: 0 5 | # Below init quaternion for `awr_6.bag`. 6 | qw: 0.999824 7 | qx: -0.000124 8 | qy: -0.015638 9 | qz: -0.010378 10 | # Below init quaternion for `awr_7.bag`. 11 | #qw: 0.999863 12 | #qx: -0.001926 13 | #qy: -0.014326 14 | #qz: -0.008075 15 | # Initial velocity. 16 | vx: 0 17 | vy: 0 18 | vz: 0 19 | # Initial IMU biases. 20 | b_wx: 0 21 | b_wy: 0 22 | b_wz: 0 23 | b_ax: 0 24 | b_ay: 0 25 | b_az: 0 26 | # IMU noise parameters. 27 | noise_acc: 0.0083 28 | noise_accbias: 0.00083 29 | noise_gyr: 0.0013 30 | noise_gyrbias: 0.00013 31 | noise_qwv: 0.0 32 | noise_qri: 0.0 33 | noise_pri: 0.0 34 | # Distance to feature. 35 | noise_meas1: 0.04 36 | # IMU. 37 | noise_meas2: 0.01 38 | # Velocity. 39 | noise_meas3: 0.035 40 | # Persistent feature noise. 0.4 41 | noise_meas4: 0.04 42 | # Below radar-IMU calibration for `awr_1 - 10` bags from 22.08.22. 43 | q_riw: 0.9170601 44 | q_rix: 0 45 | q_riy: 0.3987491 46 | q_riz: 0 47 | p_rix: 0.075 48 | p_riy: -0.01 49 | p_riz: -0.04 50 | # Not directly used parameters - needed for the autogenerated code. 51 | noise_qwv: 0.0 52 | noise_aux: 0.0 53 | noise_scale: 0.0 54 | # Noise parameters for persistent features. 0.1 55 | noise_pf_x: 0.1 56 | noise_pf_y: 0.1 57 | noise_pf_z: 0.1 58 | -------------------------------------------------------------------------------- /external/munkres-algorithm/.gitignore: -------------------------------------------------------------------------------- 1 | build 2 | example 3 | test -------------------------------------------------------------------------------- /external/munkres-algorithm/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019 Aaron Michaux 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /external/munkres-algorithm/Makefile: -------------------------------------------------------------------------------- 1 | 2 | TEST_SRCS:=example.cpp 3 | 4 | CC=gcc 5 | CPP_FLAGS:=-std=c++14 -I$(CURDIR) -Wall -Wextra -pedantic -Werror -fsanitize=address 6 | LINK_FLAGS:=-fsanitize=address -lm -lstdc++ 7 | 8 | OBJDIR:=build 9 | OBJFILES:=$(patsubst %.cpp,${OBJDIR}/%.o,${TEST_SRCS}) 10 | 11 | .PHONY: clean run_tests 12 | 13 | example: $(OBJDIR)/example.o 14 | $(CC) $(CPP_FLAGS) $(OBJDIR)/example.o $(LINK_FLAGS) -o example 15 | 16 | test: $(OBJDIR)/test.o 17 | $(CC) $(CPP_FLAGS) $(OBJDIR)/test.o $(LINK_FLAGS) -o test 18 | 19 | run_tests: test 20 | ./test 21 | 22 | $(OBJDIR)/%.o: %.cpp 23 | @mkdir -p "$$(dirname "$@")" 24 | $(CC) -x c++ $(CPP_FLAGS) -o $@ -c $< 25 | 26 | clean: 27 | rm -rf build 28 | rm -f test 29 | rm -f example 30 | 31 | -------------------------------------------------------------------------------- /external/munkres-algorithm/README.md: -------------------------------------------------------------------------------- 1 | 2 | # Munkres (Hungarian) Algorithm 3 | 4 | Modern C++ implementation of the Munkres (Hungarian) algorithm. 5 | 6 | ### Reference 7 | 8 | Implementation based on [Dr Murray Pilgram](http://csclab.murraystate.edu/~bob.pilgrim/)'s tutorial paper [Tutorial on Implementation of Munkres' Assignment Algorithm](https://www.researchgate.net/publication/290437481_Tutorial_on_Implementation_of_Munkres'_Assignment_Algorithm). 9 | 10 | There's an excellent discussion of the Munkres Algorithm at [topcoder.com](https://www.topcoder.com/community/competitive-programming/tutorials/assignment-problem-and-hungarian-algorithm/). 11 | 12 | ### Requirements 13 | 14 | * A [C++14 or C++17 compatible](https://en.cppreference.com/w/cpp/compiler_support) compiler 15 | * [GNU Make](https://www.gnu.org/software/make/) (To build and run examples.) 16 | 17 | ### Testcases 18 | 19 | Tested on Ubuntu 18.04, with [Clang 6.0](http://releases.llvm.org/6.0.1/tools/clang/docs/ReleaseNotes.html) and [gcc 7.3.0](https://www.gnu.org/software/gcc/gcc-7/). Should work without issue on [Visual Studio](https://visualstudio.microsoft.com/), or any other compiler with [C++14 or C++17 support](https://en.cppreference.com/w/cpp/compiler_support). 20 | 21 | ### Example 22 | 23 | The algorithm's interface abstracts away details of how the input graph is stored: 24 | 25 | ```c_cpp 26 | // 27 | // @param n_lhs_verts Number of left-hand-side vertices (in bipartite graph) 28 | // @param n_rhs_verts Number of right-hand-side verices (ibid) 29 | // @param cost Cost between vertices 'l' and 'r'. Use of function to abstract 30 | // away storage details of input graph. 31 | // @see example.cpp 32 | // 33 | template 34 | std::vector> inline munkres_algorithm( 35 | const unsigned n_lhs_verts, 36 | const unsigned n_rhs_verts, 37 | std::function cost) noexcept; 38 | ``` 39 | 40 | This can be used as follows (see example.cpp) 41 | 42 | ```c_cpp 43 | 44 | void some_function() 45 | { 46 | std::vector edge_weights = {40, 60, 15, 25, 30, 45, 55, 30, 25}; 47 | auto f = [&] (unsigned r, unsigned c) { return edge_weights[r * 3 + c]; }; 48 | auto matching = munkres_algorithm(3, 3, f); // That simple. 49 | } 50 | 51 | ``` 52 | 53 | -------------------------------------------------------------------------------- /external/yaml-cpp/.clang-format: -------------------------------------------------------------------------------- 1 | --- 2 | # BasedOnStyle: Google 3 | AccessModifierOffset: -1 4 | ConstructorInitializerIndentWidth: 4 5 | AlignEscapedNewlinesLeft: true 6 | AlignTrailingComments: true 7 | AllowAllParametersOfDeclarationOnNextLine: true 8 | AllowShortIfStatementsOnASingleLine: false 9 | AllowShortLoopsOnASingleLine: false 10 | AlwaysBreakTemplateDeclarations: true 11 | AlwaysBreakBeforeMultilineStrings: true 12 | BreakBeforeBinaryOperators: false 13 | BreakBeforeTernaryOperators: true 14 | BreakConstructorInitializersBeforeComma: false 15 | BinPackParameters: true 16 | ColumnLimit: 80 17 | ConstructorInitializerAllOnOneLineOrOnePerLine: true 18 | DerivePointerBinding: true 19 | ExperimentalAutoDetectBinPacking: false 20 | IndentCaseLabels: true 21 | MaxEmptyLinesToKeep: 1 22 | NamespaceIndentation: None 23 | ObjCSpaceBeforeProtocolList: false 24 | PenaltyBreakBeforeFirstCallParameter: 1 25 | PenaltyBreakComment: 60 26 | PenaltyBreakString: 1000 27 | PenaltyBreakFirstLessLess: 120 28 | PenaltyExcessCharacter: 1000000 29 | PenaltyReturnTypeOnItsOwnLine: 200 30 | PointerBindsToType: true 31 | SpacesBeforeTrailingComments: 2 32 | Cpp11BracedListStyle: true 33 | Standard: Cpp11 34 | IndentWidth: 2 35 | TabWidth: 8 36 | UseTab: Never 37 | BreakBeforeBraces: Attach 38 | IndentFunctionDeclarationAfterType: true 39 | SpacesInParentheses: false 40 | SpacesInAngles: false 41 | SpaceInEmptyParentheses: false 42 | SpacesInCStyleCastParentheses: false 43 | SpaceAfterControlStatementKeyword: true 44 | SpaceBeforeAssignmentOperators: true 45 | ContinuationIndentWidth: 4 46 | ... 47 | 48 | -------------------------------------------------------------------------------- /external/yaml-cpp/.codedocs: -------------------------------------------------------------------------------- 1 | # CodeDocs.xyz Configuration File 2 | 3 | # Optional project name, if left empty the GitHub repository name will be used. 4 | PROJECT_NAME = 5 | 6 | # One or more directories and files that contain example code to be included. 7 | EXAMPLE_PATH = 8 | 9 | # One or more directories and files to exclude from documentation generation. 10 | # Use relative paths with respect to the repository root directory. 11 | EXCLUDE = test/gtest-1.8.0/ 12 | 13 | # One or more wildcard patterns to exclude files and directories from document 14 | # generation. 15 | EXCLUDE_PATTERNS = 16 | 17 | # One or more symbols to exclude from document generation. Symbols can be 18 | # namespaces, classes, or functions. 19 | EXCLUDE_SYMBOLS = 20 | 21 | # Override the default parser (language) used for each file extension. 22 | EXTENSION_MAPPING = 23 | 24 | # Set the wildcard patterns used to filter out the source-files. 25 | # If left blank the default is: 26 | # *.c, *.cc, *.cxx, *.cpp, *.c++, *.java, *.ii, *.ixx, *.ipp, *.i++, *.inl, 27 | # *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, *.h++, *.cs, *.d, *.php, 28 | # *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, *.md, *.mm, *.dox, *.py, 29 | # *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf, *.qsf, *.as and *.js. 30 | FILE_PATTERNS = 31 | 32 | # Hide undocumented class members. 33 | HIDE_UNDOC_MEMBERS = 34 | 35 | # Hide undocumented classes. 36 | HIDE_UNDOC_CLASSES = 37 | 38 | # Specify a markdown page whose contents should be used as the main page 39 | # (index.html). This will override a page marked as \mainpage. For example, a 40 | # README.md file usually serves as a useful main page. 41 | USE_MDFILE_AS_MAINPAGE = README.md 42 | 43 | # Specify external repository to link documentation with. 44 | # This is similar to Doxygen's TAGFILES option, but will automatically link to 45 | # tags of other repositories already using CodeDocs. List each repository to 46 | # link with by giving its location in the form of owner/repository. 47 | # For example: 48 | # TAGLINKS = doxygen/doxygen CodeDocs/osg 49 | # Note: these repositories must already be built on CodeDocs. 50 | TAGLINKS = 51 | -------------------------------------------------------------------------------- /external/yaml-cpp/.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | name: Github PR 2 | on: 3 | push: 4 | branches: [ master ] 5 | pull_request: 6 | branches: [ master ] 7 | workflow_dispatch: 8 | jobs: 9 | build: 10 | strategy: 11 | matrix: 12 | os: [ubuntu-latest, windows-latest, macos-latest] 13 | runs-on: ${{ matrix.os }} 14 | steps: 15 | - uses: actions/checkout@v2 16 | 17 | - name: Build static 18 | shell: bash 19 | run: | 20 | mkdir -p build && cd build 21 | cmake .. 22 | cmake --build . --parallel 4 23 | 24 | - name: Test static 25 | shell: bash 26 | run: cd build && ctest --output-on-failure 27 | 28 | - name: Build shared 29 | shell: bash 30 | run: | 31 | rm -rf build && mkdir -p build && cd build 32 | cmake .. -DYAML_BUILD_SHARED_LIBS=ON 33 | cmake --build . --parallel 4 34 | 35 | # tests are failing for unknown reasons 36 | - if: matrix.os == 'ubuntu-latest' 37 | name: Test shared 38 | shell: bash 39 | run: cd build && ctest --output-on-failure 40 | # test all ASAP 41 | -------------------------------------------------------------------------------- /external/yaml-cpp/.gitignore: -------------------------------------------------------------------------------- 1 | build/ 2 | /tags 3 | /bazel-* 4 | -------------------------------------------------------------------------------- /external/yaml-cpp/.travis.yml: -------------------------------------------------------------------------------- 1 | language: c++ 2 | 3 | matrix: 4 | include: 5 | - os: linux 6 | compiler: gcc 7 | - os: osx 8 | compiler: clang 9 | - os: osx 10 | compiler: gcc 11 | env: 12 | - CTEST_OUTPUT_ON_FAILURE=1 13 | 14 | before_script: 15 | - mkdir build 16 | - cd build 17 | - cmake .. 18 | - cd .. 19 | script: 20 | - cmake --build build 21 | - cmake --build build --target test 22 | 23 | addons: 24 | apt: 25 | sources: 26 | - ubuntu-toolchain-r-test 27 | - llvm-toolchain-precise-3.9 28 | packages: 29 | - g++-4.9 30 | - clang-3.9 31 | update: true 32 | homebrew: 33 | packages: 34 | - ccache 35 | - gcc@4.9 36 | - llvm@4 37 | update: true 38 | -------------------------------------------------------------------------------- /external/yaml-cpp/BUILD.bazel: -------------------------------------------------------------------------------- 1 | cc_library( 2 | name = "yaml-cpp_internal", 3 | visibility = ["//:__subpackages__"], 4 | strip_include_prefix = "src", 5 | hdrs = glob(["src/**/*.h"]), 6 | ) 7 | 8 | cc_library( 9 | name = "yaml-cpp", 10 | visibility = ["//visibility:public"], 11 | includes = ["include"], 12 | hdrs = glob(["include/**/*.h"]), 13 | srcs = glob(["src/**/*.cpp", "src/**/*.h"]), 14 | ) 15 | -------------------------------------------------------------------------------- /external/yaml-cpp/CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Style 2 | 3 | This project is formatted with [clang-format][fmt] using the style file at the root of the repository. Please run clang-format before sending a pull request. 4 | 5 | In general, try to follow the style of surrounding code. We mostly follow the [Google C++ style guide][cpp-style]. 6 | 7 | Commit messages should be in the imperative mood, as described in the [Git contributing file][git-contrib]: 8 | 9 | > Describe your changes in imperative mood, e.g. "make xyzzy do frotz" 10 | > instead of "[This patch] makes xyzzy do frotz" or "[I] changed xyzzy 11 | > to do frotz", as if you are giving orders to the codebase to change 12 | > its behaviour. 13 | 14 | [fmt]: http://clang.llvm.org/docs/ClangFormat.html 15 | [cpp-style]: https://google.github.io/styleguide/cppguide.html 16 | [git-contrib]: http://git.kernel.org/cgit/git/git.git/tree/Documentation/SubmittingPatches?id=HEAD 17 | 18 | # Tests 19 | 20 | Please verify the tests pass by running the target `tests/run_tests`. 21 | 22 | If you are adding functionality, add tests accordingly. 23 | 24 | # Pull request process 25 | 26 | Every pull request undergoes a code review. Unfortunately, github's code review process isn't great, but we'll manage. During the code review, if you make changes, add new commits to the pull request for each change. Once the code review is complete, rebase against the master branch and squash into a single commit. 27 | -------------------------------------------------------------------------------- /external/yaml-cpp/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2008-2015 Jesse Beder. 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in 11 | all copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | -------------------------------------------------------------------------------- /external/yaml-cpp/WORKSPACE: -------------------------------------------------------------------------------- 1 | workspace(name = "com_github_jbeder_yaml_cpp") 2 | 3 | load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") 4 | 5 | http_archive( 6 | name = "com_google_googletest", 7 | strip_prefix = "googletest-release-1.8.1", 8 | url = "https://github.com/google/googletest/archive/release-1.8.1.tar.gz", 9 | sha256 = "9bf1fe5182a604b4135edc1a425ae356c9ad15e9b23f9f12a02e80184c3a249c", 10 | ) 11 | -------------------------------------------------------------------------------- /external/yaml-cpp/appveyor.yml: -------------------------------------------------------------------------------- 1 | version: 1.0.{build} 2 | 3 | environment: 4 | matrix: 5 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015 6 | CMAKE_GENERATOR: Visual Studio 14 2015 7 | CMAKE_PLATFORM: win32 8 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015 9 | CMAKE_GENERATOR: Visual Studio 14 2015 10 | CMAKE_PLATFORM: x64 11 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 12 | CMAKE_GENERATOR: Visual Studio 15 2017 13 | CMAKE_PLATFORM: win32 14 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 15 | CMAKE_GENERATOR: Visual Studio 15 2017 16 | CMAKE_PLATFORM: x64 17 | 18 | before_build: 19 | - cmd: mkdir build 20 | - cmd: cd build 21 | - cmd: cmake .. -G "%CMAKE_GENERATOR%" -DCMAKE_GENERATOR_PLATFORM=%CMAKE_PLATFORM% 22 | - cmd: cd .. 23 | 24 | build_script: 25 | - cmake --build build 26 | test_script: 27 | - cmd: cd build 28 | - ctest 29 | -------------------------------------------------------------------------------- /external/yaml-cpp/docs/Breaking-Changes.md: -------------------------------------------------------------------------------- 1 | # The following is a list of breaking changes to yaml-cpp, by version # 2 | 3 | # New API # 4 | 5 | ## HEAD ## 6 | 7 | * Throws an exception when trying to parse a negative number as an unsigned integer. 8 | * Supports the `as`/`as`, which throws an exception when the value exceeds the range of `int8_t`/`uint8_t`. 9 | 10 | ## 0.6.0 ## 11 | 12 | * Requires C++11. 13 | 14 | ## 0.5.3 ## 15 | 16 | _none_ 17 | 18 | ## 0.5.2 ## 19 | 20 | _none_ 21 | 22 | ## 0.5.1 ## 23 | 24 | * `Node::clear` was replaced by `Node::reset`, which takes an optional node, similar to smart pointers. 25 | 26 | ## 0.5.0 ## 27 | 28 | Initial version of the new API. 29 | 30 | # Old API # 31 | 32 | ## 0.3.0 ## 33 | 34 | _none_ 35 | 36 | ## 0.2.7 ## 37 | 38 | * `YAML::Binary` now takes `const unsigned char *` for the binary data (instead of `const char *`). 39 | 40 | ## 0.2.6 ## 41 | 42 | * `Node::GetType()` is now `Node::Type()`, and returns an enum `NodeType::value`, where: 43 | > > ` struct NodeType { enum value { Null, Scalar, Sequence, Map }; }; ` 44 | * `Node::GetTag()` is now `Node::Tag()` 45 | * `Node::Identity()` is removed, and `Node::IsAlias()` and `Node::IsReferenced()` have been merged into `Node::IsAliased()`. The reason: there's no reason to distinguish an alias node from its anchor - whichever happens to be emitted first will be the anchor, and the rest will be aliases. 46 | * `Node::Read` is now `Node::to`. This wasn't a documented function, so it shouldn't break anything. 47 | * `Node`'s comparison operators (for example, `operator == (const Node&, const T&)`) have all been removed. These weren't documented either (they were just used for the tests), so this shouldn't break anything either. 48 | * The emitter no longer produces the document start by default - if you want it, you can supply it with the manipulator `YAML::BeginDoc`. 49 | 50 | ## 0.2.5 ## 51 | 52 | This wiki was started with v0.2.5. -------------------------------------------------------------------------------- /external/yaml-cpp/docs/Strings.md: -------------------------------------------------------------------------------- 1 | # Encodings and `yaml-cpp` # 2 | 3 | `yaml-cpp` will parse any file as specified by the [YAML 1.2 spec](http://www.yaml.org/spec/1.2/spec.html#id2570322). Internally, it stores all strings in UTF-8, and representation is done with UTF-8. This means that in 4 | 5 | ``` 6 | std::string str; 7 | node >> str; 8 | ``` 9 | 10 | `str` will be UTF-8. Similarly, if you're accessing a map by string key, you need to pass the key in UTF-8. If your application uses a different encoding, you need to convert to and from UTF-8 to work with `yaml-cpp`. (It's possible we'll add some small conversion functions, but for now it's restricted.) 11 | 12 | --- 13 | 14 | For convenience, Richard Weeks has kindly provided a google gadget that converts Unicode to a string literal. It's a Google Gadget, so unfortunately it does not work on GitHub. Patches welcome to port it to a usable format here: 15 | 16 | ``` 17 | 18 | ``` -------------------------------------------------------------------------------- /external/yaml-cpp/docs/_config.yml: -------------------------------------------------------------------------------- 1 | theme: jekyll-theme-slate -------------------------------------------------------------------------------- /external/yaml-cpp/docs/index.md: -------------------------------------------------------------------------------- 1 | To learn how to use the library, see the [Tutorial](https://github.com/jbeder/yaml-cpp/wiki/Tutorial) and [How To Emit YAML](https://github.com/jbeder/yaml-cpp/wiki/How-To-Emit-YAML) 2 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/anchor.h: -------------------------------------------------------------------------------- 1 | #ifndef ANCHOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define ANCHOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | 12 | namespace YAML { 13 | using anchor_t = std::size_t; 14 | const anchor_t NullAnchor = 0; 15 | } 16 | 17 | #endif // ANCHOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 18 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/contrib/anchordict.h: -------------------------------------------------------------------------------- 1 | #ifndef ANCHORDICT_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define ANCHORDICT_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | 12 | #include "../anchor.h" 13 | 14 | namespace YAML { 15 | /** 16 | * An object that stores and retrieves values correlating to {@link anchor_t} 17 | * values. 18 | * 19 | *

Efficient implementation that can make assumptions about how 20 | * {@code anchor_t} values are assigned by the {@link Parser} class. 21 | */ 22 | template 23 | class AnchorDict { 24 | public: 25 | AnchorDict() : m_data{} {} 26 | void Register(anchor_t anchor, T value) { 27 | if (anchor > m_data.size()) { 28 | m_data.resize(anchor); 29 | } 30 | m_data[anchor - 1] = value; 31 | } 32 | 33 | T Get(anchor_t anchor) const { return m_data[anchor - 1]; } 34 | 35 | private: 36 | std::vector m_data; 37 | }; 38 | } // namespace YAML 39 | 40 | #endif // ANCHORDICT_H_62B23520_7C8E_11DE_8A39_0800200C9A66 41 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/dll.h: -------------------------------------------------------------------------------- 1 | #ifndef DLL_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define DLL_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | // Definition YAML_CPP_STATIC_DEFINE using to building YAML-CPP as static 5 | // library (definition created by CMake or defined manually) 6 | 7 | // Definition yaml_cpp_EXPORTS using to building YAML-CPP as dll/so library 8 | // (definition created by CMake or defined manually) 9 | 10 | #ifdef YAML_CPP_STATIC_DEFINE 11 | # define YAML_CPP_API 12 | # define YAML_CPP_NO_EXPORT 13 | #else 14 | # if defined(_MSC_VER) || defined(__MINGW32__) || defined(__MINGW64__) 15 | # ifndef YAML_CPP_API 16 | # ifdef yaml_cpp_EXPORTS 17 | /* We are building this library */ 18 | # pragma message( "Defining YAML_CPP_API for DLL export" ) 19 | # define YAML_CPP_API __declspec(dllexport) 20 | # else 21 | /* We are using this library */ 22 | # pragma message( "Defining YAML_CPP_API for DLL import" ) 23 | # define YAML_CPP_API __declspec(dllimport) 24 | # endif 25 | # endif 26 | # ifndef YAML_CPP_NO_EXPORT 27 | # define YAML_CPP_NO_EXPORT 28 | # endif 29 | # else /* No _MSC_VER */ 30 | # ifndef YAML_CPP_API 31 | # ifdef yaml_cpp_EXPORTS 32 | /* We are building this library */ 33 | # define YAML_CPP_API __attribute__((visibility("default"))) 34 | # else 35 | /* We are using this library */ 36 | # define YAML_CPP_API __attribute__((visibility("default"))) 37 | # endif 38 | # endif 39 | # ifndef YAML_CPP_NO_EXPORT 40 | # define YAML_CPP_NO_EXPORT __attribute__((visibility("hidden"))) 41 | # endif 42 | # endif /* _MSC_VER */ 43 | #endif /* YAML_CPP_STATIC_DEFINE */ 44 | 45 | #ifndef YAML_CPP_DEPRECATED 46 | # ifdef _MSC_VER 47 | # define YAML_CPP_DEPRECATED __declspec(deprecated) 48 | # else 49 | # define YAML_CPP_DEPRECATED __attribute__ ((__deprecated__)) 50 | # endif 51 | #endif 52 | 53 | #ifndef YAML_CPP_DEPRECATED_EXPORT 54 | # define YAML_CPP_DEPRECATED_EXPORT YAML_CPP_API YAML_CPP_DEPRECATED 55 | #endif 56 | 57 | #ifndef YAML_CPP_DEPRECATED_NO_EXPORT 58 | # define YAML_CPP_DEPRECATED_NO_EXPORT YAML_CPP_NO_EXPORT YAML_CPP_DEPRECATED 59 | #endif 60 | 61 | #endif /* DLL_H_62B23520_7C8E_11DE_8A39_0800200C9A66 */ 62 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/emitfromevents.h: -------------------------------------------------------------------------------- 1 | #ifndef EMITFROMEVENTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define EMITFROMEVENTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | 12 | #include "yaml-cpp/anchor.h" 13 | #include "yaml-cpp/emitterstyle.h" 14 | #include "yaml-cpp/eventhandler.h" 15 | 16 | namespace YAML { 17 | struct Mark; 18 | } // namespace YAML 19 | 20 | namespace YAML { 21 | class Emitter; 22 | 23 | class EmitFromEvents : public EventHandler { 24 | public: 25 | EmitFromEvents(Emitter& emitter); 26 | 27 | void OnDocumentStart(const Mark& mark) override; 28 | void OnDocumentEnd() override; 29 | 30 | void OnNull(const Mark& mark, anchor_t anchor) override; 31 | void OnAlias(const Mark& mark, anchor_t anchor) override; 32 | void OnScalar(const Mark& mark, const std::string& tag, 33 | anchor_t anchor, const std::string& value) override; 34 | 35 | void OnSequenceStart(const Mark& mark, const std::string& tag, 36 | anchor_t anchor, EmitterStyle::value style) override; 37 | void OnSequenceEnd() override; 38 | 39 | void OnMapStart(const Mark& mark, const std::string& tag, 40 | anchor_t anchor, EmitterStyle::value style) override; 41 | void OnMapEnd() override; 42 | 43 | private: 44 | void BeginNode(); 45 | void EmitProps(const std::string& tag, anchor_t anchor); 46 | 47 | private: 48 | Emitter& m_emitter; 49 | 50 | struct State { 51 | enum value { WaitingForSequenceEntry, WaitingForKey, WaitingForValue }; 52 | }; 53 | std::stack m_stateStack; 54 | }; 55 | } 56 | 57 | #endif // EMITFROMEVENTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 58 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/emitterdef.h: -------------------------------------------------------------------------------- 1 | #ifndef EMITTERDEF_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define EMITTERDEF_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | namespace YAML { 11 | struct EmitterNodeType { 12 | enum value { NoType, Property, Scalar, FlowSeq, BlockSeq, FlowMap, BlockMap }; 13 | }; 14 | } 15 | 16 | #endif // EMITTERDEF_H_62B23520_7C8E_11DE_8A39_0800200C9A66 17 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/emitterstyle.h: -------------------------------------------------------------------------------- 1 | #ifndef EMITTERSTYLE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define EMITTERSTYLE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | namespace YAML { 11 | struct EmitterStyle { 12 | enum value { Default, Block, Flow }; 13 | }; 14 | } 15 | 16 | #endif // EMITTERSTYLE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 17 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/eventhandler.h: -------------------------------------------------------------------------------- 1 | #ifndef EVENTHANDLER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define EVENTHANDLER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | 12 | #include "yaml-cpp/anchor.h" 13 | #include "yaml-cpp/emitterstyle.h" 14 | 15 | namespace YAML { 16 | struct Mark; 17 | 18 | class EventHandler { 19 | public: 20 | virtual ~EventHandler() = default; 21 | 22 | virtual void OnDocumentStart(const Mark& mark) = 0; 23 | virtual void OnDocumentEnd() = 0; 24 | 25 | virtual void OnNull(const Mark& mark, anchor_t anchor) = 0; 26 | virtual void OnAlias(const Mark& mark, anchor_t anchor) = 0; 27 | virtual void OnScalar(const Mark& mark, const std::string& tag, 28 | anchor_t anchor, const std::string& value) = 0; 29 | 30 | virtual void OnSequenceStart(const Mark& mark, const std::string& tag, 31 | anchor_t anchor, EmitterStyle::value style) = 0; 32 | virtual void OnSequenceEnd() = 0; 33 | 34 | virtual void OnMapStart(const Mark& mark, const std::string& tag, 35 | anchor_t anchor, EmitterStyle::value style) = 0; 36 | virtual void OnMapEnd() = 0; 37 | 38 | virtual void OnAnchor(const Mark& /*mark*/, 39 | const std::string& /*anchor_name*/) { 40 | // empty default implementation for compatibility 41 | } 42 | }; 43 | } // namespace YAML 44 | 45 | #endif // EVENTHANDLER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 46 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/mark.h: -------------------------------------------------------------------------------- 1 | #ifndef MARK_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define MARK_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include "yaml-cpp/dll.h" 11 | 12 | namespace YAML { 13 | struct YAML_CPP_API Mark { 14 | Mark() : pos(0), line(0), column(0) {} 15 | 16 | static const Mark null_mark() { return Mark(-1, -1, -1); } 17 | 18 | bool is_null() const { return pos == -1 && line == -1 && column == -1; } 19 | 20 | int pos; 21 | int line, column; 22 | 23 | private: 24 | Mark(int pos_, int line_, int column_) 25 | : pos(pos_), line(line_), column(column_) {} 26 | }; 27 | } 28 | 29 | #endif // MARK_H_62B23520_7C8E_11DE_8A39_0800200C9A66 30 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/node/detail/iterator_fwd.h: -------------------------------------------------------------------------------- 1 | #ifndef VALUE_DETAIL_ITERATOR_FWD_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define VALUE_DETAIL_ITERATOR_FWD_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include "yaml-cpp/dll.h" 11 | #include 12 | #include 13 | #include 14 | 15 | namespace YAML { 16 | 17 | namespace detail { 18 | struct iterator_value; 19 | template 20 | class iterator_base; 21 | } 22 | 23 | using iterator = detail::iterator_base; 24 | using const_iterator = detail::iterator_base; 25 | } 26 | 27 | #endif // VALUE_DETAIL_ITERATOR_FWD_H_62B23520_7C8E_11DE_8A39_0800200C9A66 28 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/node/detail/memory.h: -------------------------------------------------------------------------------- 1 | #ifndef VALUE_DETAIL_MEMORY_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define VALUE_DETAIL_MEMORY_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | 12 | #include "yaml-cpp/dll.h" 13 | #include "yaml-cpp/node/ptr.h" 14 | 15 | namespace YAML { 16 | namespace detail { 17 | class node; 18 | } // namespace detail 19 | } // namespace YAML 20 | 21 | namespace YAML { 22 | namespace detail { 23 | class YAML_CPP_API memory { 24 | public: 25 | memory() : m_nodes{} {} 26 | node& create_node(); 27 | void merge(const memory& rhs); 28 | 29 | private: 30 | using Nodes = std::set; 31 | Nodes m_nodes; 32 | }; 33 | 34 | class YAML_CPP_API memory_holder { 35 | public: 36 | memory_holder() : m_pMemory(new memory) {} 37 | 38 | node& create_node() { return m_pMemory->create_node(); } 39 | void merge(memory_holder& rhs); 40 | 41 | private: 42 | shared_memory m_pMemory; 43 | }; 44 | } // namespace detail 45 | } // namespace YAML 46 | 47 | #endif // VALUE_DETAIL_MEMORY_H_62B23520_7C8E_11DE_8A39_0800200C9A66 48 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/node/emit.h: -------------------------------------------------------------------------------- 1 | #ifndef NODE_EMIT_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define NODE_EMIT_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | #include 12 | 13 | #include "yaml-cpp/dll.h" 14 | 15 | namespace YAML { 16 | class Emitter; 17 | class Node; 18 | 19 | /** 20 | * Emits the node to the given {@link Emitter}. If there is an error in writing, 21 | * {@link Emitter#good} will return false. 22 | */ 23 | YAML_CPP_API Emitter& operator<<(Emitter& out, const Node& node); 24 | 25 | /** Emits the node to the given output stream. */ 26 | YAML_CPP_API std::ostream& operator<<(std::ostream& out, const Node& node); 27 | 28 | /** Converts the node to a YAML string. */ 29 | YAML_CPP_API std::string Dump(const Node& node); 30 | } // namespace YAML 31 | 32 | #endif // NODE_EMIT_H_62B23520_7C8E_11DE_8A39_0800200C9A66 33 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/node/iterator.h: -------------------------------------------------------------------------------- 1 | #ifndef VALUE_ITERATOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define VALUE_ITERATOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include "yaml-cpp/dll.h" 11 | #include "yaml-cpp/node/node.h" 12 | #include "yaml-cpp/node/detail/iterator_fwd.h" 13 | #include "yaml-cpp/node/detail/iterator.h" 14 | #include 15 | #include 16 | #include 17 | 18 | // Assert in place so gcc + libc++ combination properly builds 19 | static_assert(std::is_constructible::value, "Node must be copy constructable"); 20 | 21 | namespace YAML { 22 | namespace detail { 23 | struct iterator_value : public Node, std::pair { 24 | iterator_value() = default; 25 | explicit iterator_value(const Node& rhs) 26 | : Node(rhs), 27 | std::pair(Node(Node::ZombieNode), Node(Node::ZombieNode)) {} 28 | explicit iterator_value(const Node& key, const Node& value) 29 | : Node(Node::ZombieNode), std::pair(key, value) {} 30 | }; 31 | } 32 | } 33 | 34 | #endif // VALUE_ITERATOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 35 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/node/ptr.h: -------------------------------------------------------------------------------- 1 | #ifndef VALUE_PTR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define VALUE_PTR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include "yaml-cpp/dll.h" 11 | #include 12 | 13 | namespace YAML { 14 | namespace detail { 15 | class node; 16 | class node_ref; 17 | class node_data; 18 | class memory; 19 | class memory_holder; 20 | 21 | using shared_node = std::shared_ptr; 22 | using shared_node_ref = std::shared_ptr; 23 | using shared_node_data = std::shared_ptr; 24 | using shared_memory_holder = std::shared_ptr; 25 | using shared_memory = std::shared_ptr; 26 | } 27 | } 28 | 29 | #endif // VALUE_PTR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 30 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/node/type.h: -------------------------------------------------------------------------------- 1 | #ifndef VALUE_TYPE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define VALUE_TYPE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | namespace YAML { 11 | struct NodeType { 12 | enum value { Undefined, Null, Scalar, Sequence, Map }; 13 | }; 14 | } 15 | 16 | #endif // VALUE_TYPE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 17 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/noexcept.h: -------------------------------------------------------------------------------- 1 | #ifndef NOEXCEPT_H_768872DA_476C_11EA_88B8_90B11C0C0FF8 2 | #define NOEXCEPT_H_768872DA_476C_11EA_88B8_90B11C0C0FF8 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | // This is here for compatibility with older versions of Visual Studio 11 | // which don't support noexcept. 12 | #if defined(_MSC_VER) && _MSC_VER < 1900 13 | #define YAML_CPP_NOEXCEPT _NOEXCEPT 14 | #else 15 | #define YAML_CPP_NOEXCEPT noexcept 16 | #endif 17 | 18 | #endif 19 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/null.h: -------------------------------------------------------------------------------- 1 | #ifndef NULL_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define NULL_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include "yaml-cpp/dll.h" 11 | #include 12 | 13 | namespace YAML { 14 | class Node; 15 | 16 | struct YAML_CPP_API _Null {}; 17 | inline bool operator==(const _Null&, const _Null&) { return true; } 18 | inline bool operator!=(const _Null&, const _Null&) { return false; } 19 | 20 | YAML_CPP_API bool IsNull(const Node& node); // old API only 21 | YAML_CPP_API bool IsNullString(const std::string& str); 22 | 23 | extern YAML_CPP_API _Null Null; 24 | } 25 | 26 | #endif // NULL_H_62B23520_7C8E_11DE_8A39_0800200C9A66 27 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/stlemitter.h: -------------------------------------------------------------------------------- 1 | #ifndef STLEMITTER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define STLEMITTER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | #include 12 | #include 13 | #include 14 | 15 | namespace YAML { 16 | template 17 | inline Emitter& EmitSeq(Emitter& emitter, const Seq& seq) { 18 | emitter << BeginSeq; 19 | for (const auto& v : seq) 20 | emitter << v; 21 | emitter << EndSeq; 22 | return emitter; 23 | } 24 | 25 | template 26 | inline Emitter& operator<<(Emitter& emitter, const std::vector& v) { 27 | return EmitSeq(emitter, v); 28 | } 29 | 30 | template 31 | inline Emitter& operator<<(Emitter& emitter, const std::list& v) { 32 | return EmitSeq(emitter, v); 33 | } 34 | 35 | template 36 | inline Emitter& operator<<(Emitter& emitter, const std::set& v) { 37 | return EmitSeq(emitter, v); 38 | } 39 | 40 | template 41 | inline Emitter& operator<<(Emitter& emitter, const std::map& m) { 42 | emitter << BeginMap; 43 | for (const auto& v : m) 44 | emitter << Key << v.first << Value << v.second; 45 | emitter << EndMap; 46 | return emitter; 47 | } 48 | } 49 | 50 | #endif // STLEMITTER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 51 | -------------------------------------------------------------------------------- /external/yaml-cpp/include/yaml-cpp/yaml.h: -------------------------------------------------------------------------------- 1 | #ifndef YAML_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define YAML_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include "yaml-cpp/parser.h" 11 | #include "yaml-cpp/emitter.h" 12 | #include "yaml-cpp/emitterstyle.h" 13 | #include "yaml-cpp/stlemitter.h" 14 | #include "yaml-cpp/exceptions.h" 15 | 16 | #include "yaml-cpp/node/node.h" 17 | #include "yaml-cpp/node/impl.h" 18 | #include "yaml-cpp/node/convert.h" 19 | #include "yaml-cpp/node/iterator.h" 20 | #include "yaml-cpp/node/detail/impl.h" 21 | #include "yaml-cpp/node/parse.h" 22 | #include "yaml-cpp/node/emit.h" 23 | 24 | #endif // YAML_H_62B23520_7C8E_11DE_8A39_0800200C9A66 25 | -------------------------------------------------------------------------------- /external/yaml-cpp/install.txt: -------------------------------------------------------------------------------- 1 | *** With CMake *** 2 | 3 | yaml-cpp uses CMake to support cross-platform building. In a UNIX-like system, the basic steps to build are: 4 | 5 | 1. Download and install CMake (if you don't have root privileges, just install to a local directory, like ~/bin) 6 | 7 | 2. From the source directory, run: 8 | 9 | mkdir build 10 | cd build 11 | cmake .. 12 | 13 | and then the usual 14 | 15 | make 16 | make install 17 | 18 | 3. To clean up, just remove the 'build' directory. 19 | 20 | *** Without CMake *** 21 | 22 | If you don't want to use CMake, just add all .cpp files to a makefile. yaml-cpp does not need any special build settings, so no 'configure' file is necessary. 23 | 24 | (Note: this is pretty tedious. It's sooo much easier to use CMake.) 25 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/collectionstack.h: -------------------------------------------------------------------------------- 1 | #ifndef COLLECTIONSTACK_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define COLLECTIONSTACK_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | #include 12 | 13 | namespace YAML { 14 | struct CollectionType { 15 | enum value { NoCollection, BlockMap, BlockSeq, FlowMap, FlowSeq, CompactMap }; 16 | }; 17 | 18 | class CollectionStack { 19 | public: 20 | CollectionStack() : collectionStack{} {} 21 | CollectionType::value GetCurCollectionType() const { 22 | if (collectionStack.empty()) 23 | return CollectionType::NoCollection; 24 | return collectionStack.top(); 25 | } 26 | 27 | void PushCollectionType(CollectionType::value type) { 28 | collectionStack.push(type); 29 | } 30 | void PopCollectionType(CollectionType::value type) { 31 | assert(type == GetCurCollectionType()); 32 | (void)type; 33 | collectionStack.pop(); 34 | } 35 | 36 | private: 37 | std::stack collectionStack; 38 | }; 39 | } // namespace YAML 40 | 41 | #endif // COLLECTIONSTACK_H_62B23520_7C8E_11DE_8A39_0800200C9A66 42 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/contrib/graphbuilder.cpp: -------------------------------------------------------------------------------- 1 | #include "graphbuilderadapter.h" 2 | 3 | #include "yaml-cpp/parser.h" // IWYU pragma: keep 4 | 5 | namespace YAML { 6 | class GraphBuilderInterface; 7 | 8 | void* BuildGraphOfNextDocument(Parser& parser, 9 | GraphBuilderInterface& graphBuilder) { 10 | GraphBuilderAdapter eventHandler(graphBuilder); 11 | if (parser.HandleNextDocument(eventHandler)) { 12 | return eventHandler.RootNode(); 13 | } 14 | return nullptr; 15 | } 16 | } // namespace YAML 17 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/contrib/yaml-cpp.natvis.md: -------------------------------------------------------------------------------- 1 | # MSVC debugger visualizer for YAML::Node 2 | 3 | ## How to use 4 | Add yaml-cpp.natvis to your Visual C++ project like any other source file. It will be included in the debug information, and improve debugger display on YAML::Node and contained types. 5 | 6 | ## Compatibility and Troubleshooting 7 | 8 | This has been tested for MSVC 2017. It is expected to be compatible with VS 2015 and VS 2019. If you have any problems, you can open an issue here: https://github.com/peterchen-cp/yaml-cpp-natvis 9 | 10 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/convert.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #include "yaml-cpp/node/convert.h" 4 | 5 | namespace { 6 | // we're not gonna mess with the mess that is all the isupper/etc. functions 7 | bool IsLower(char ch) { return 'a' <= ch && ch <= 'z'; } 8 | bool IsUpper(char ch) { return 'A' <= ch && ch <= 'Z'; } 9 | char ToLower(char ch) { return IsUpper(ch) ? ch + 'a' - 'A' : ch; } 10 | 11 | std::string tolower(const std::string& str) { 12 | std::string s(str); 13 | std::transform(s.begin(), s.end(), s.begin(), ToLower); 14 | return s; 15 | } 16 | 17 | template 18 | bool IsEntirely(const std::string& str, T func) { 19 | return std::all_of(str.begin(), str.end(), [=](char ch) { return func(ch); }); 20 | } 21 | 22 | // IsFlexibleCase 23 | // . Returns true if 'str' is: 24 | // . UPPERCASE 25 | // . lowercase 26 | // . Capitalized 27 | bool IsFlexibleCase(const std::string& str) { 28 | if (str.empty()) 29 | return true; 30 | 31 | if (IsEntirely(str, IsLower)) 32 | return true; 33 | 34 | bool firstcaps = IsUpper(str[0]); 35 | std::string rest = str.substr(1); 36 | return firstcaps && (IsEntirely(rest, IsLower) || IsEntirely(rest, IsUpper)); 37 | } 38 | } // namespace 39 | 40 | namespace YAML { 41 | bool convert::decode(const Node& node, bool& rhs) { 42 | if (!node.IsScalar()) 43 | return false; 44 | 45 | // we can't use iostream bool extraction operators as they don't 46 | // recognize all possible values in the table below (taken from 47 | // http://yaml.org/type/bool.html) 48 | static const struct { 49 | std::string truename, falsename; 50 | } names[] = { 51 | {"y", "n"}, 52 | {"yes", "no"}, 53 | {"true", "false"}, 54 | {"on", "off"}, 55 | }; 56 | 57 | if (!IsFlexibleCase(node.Scalar())) 58 | return false; 59 | 60 | for (const auto& name : names) { 61 | if (name.truename == tolower(node.Scalar())) { 62 | rhs = true; 63 | return true; 64 | } 65 | 66 | if (name.falsename == tolower(node.Scalar())) { 67 | rhs = false; 68 | return true; 69 | } 70 | } 71 | 72 | return false; 73 | } 74 | } // namespace YAML 75 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/depthguard.cpp: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/depthguard.h" 2 | 3 | namespace YAML { 4 | 5 | DeepRecursion::DeepRecursion(int depth, const Mark& mark_, 6 | const std::string& msg_) 7 | : ParserException(mark_, msg_), m_depth(depth) {} 8 | 9 | } // namespace YAML 10 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/directives.cpp: -------------------------------------------------------------------------------- 1 | #include "directives.h" 2 | 3 | namespace YAML { 4 | Directives::Directives() : version{true, 1, 2}, tags{} {} 5 | 6 | const std::string Directives::TranslateTagHandle( 7 | const std::string& handle) const { 8 | auto it = tags.find(handle); 9 | if (it == tags.end()) { 10 | if (handle == "!!") 11 | return "tag:yaml.org,2002:"; 12 | return handle; 13 | } 14 | 15 | return it->second; 16 | } 17 | } // namespace YAML 18 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/directives.h: -------------------------------------------------------------------------------- 1 | #ifndef DIRECTIVES_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define DIRECTIVES_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | #include 12 | 13 | namespace YAML { 14 | struct Version { 15 | bool isDefault; 16 | int major, minor; 17 | }; 18 | 19 | struct Directives { 20 | Directives(); 21 | 22 | const std::string TranslateTagHandle(const std::string& handle) const; 23 | 24 | Version version; 25 | std::map tags; 26 | }; 27 | } 28 | 29 | #endif // DIRECTIVES_H_62B23520_7C8E_11DE_8A39_0800200C9A66 30 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/emit.cpp: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/node/emit.h" 2 | #include "nodeevents.h" 3 | #include "yaml-cpp/emitfromevents.h" 4 | #include "yaml-cpp/emitter.h" 5 | 6 | namespace YAML { 7 | Emitter& operator<<(Emitter& out, const Node& node) { 8 | EmitFromEvents emitFromEvents(out); 9 | NodeEvents events(node); 10 | events.Emit(emitFromEvents); 11 | return out; 12 | } 13 | 14 | std::ostream& operator<<(std::ostream& out, const Node& node) { 15 | Emitter emitter(out); 16 | emitter << node; 17 | return out; 18 | } 19 | 20 | std::string Dump(const Node& node) { 21 | Emitter emitter; 22 | emitter << node; 23 | return emitter.c_str(); 24 | } 25 | } // namespace YAML 26 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/emitterutils.h: -------------------------------------------------------------------------------- 1 | #ifndef EMITTERUTILS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define EMITTERUTILS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | 12 | #include "emitterstate.h" 13 | #include "yaml-cpp/emittermanip.h" 14 | #include "yaml-cpp/ostream_wrapper.h" 15 | 16 | namespace YAML { 17 | class ostream_wrapper; 18 | } // namespace YAML 19 | 20 | namespace YAML { 21 | class Binary; 22 | 23 | struct StringFormat { 24 | enum value { Plain, SingleQuoted, DoubleQuoted, Literal }; 25 | }; 26 | 27 | struct StringEscaping { 28 | enum value { None, NonAscii, JSON }; 29 | }; 30 | 31 | namespace Utils { 32 | StringFormat::value ComputeStringFormat(const std::string& str, 33 | EMITTER_MANIP strFormat, 34 | FlowType::value flowType, 35 | bool escapeNonAscii); 36 | 37 | bool WriteSingleQuotedString(ostream_wrapper& out, const std::string& str); 38 | bool WriteDoubleQuotedString(ostream_wrapper& out, const std::string& str, 39 | StringEscaping::value stringEscaping); 40 | bool WriteLiteralString(ostream_wrapper& out, const std::string& str, 41 | std::size_t indent); 42 | bool WriteChar(ostream_wrapper& out, char ch, 43 | StringEscaping::value stringEscapingStyle); 44 | bool WriteComment(ostream_wrapper& out, const std::string& str, 45 | std::size_t postCommentIndent); 46 | bool WriteAlias(ostream_wrapper& out, const std::string& str); 47 | bool WriteAnchor(ostream_wrapper& out, const std::string& str); 48 | bool WriteTag(ostream_wrapper& out, const std::string& str, bool verbatim); 49 | bool WriteTagWithPrefix(ostream_wrapper& out, const std::string& prefix, 50 | const std::string& tag); 51 | bool WriteBinary(ostream_wrapper& out, const Binary& binary); 52 | } 53 | } 54 | 55 | #endif // EMITTERUTILS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 56 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/exceptions.cpp: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/exceptions.h" 2 | #include "yaml-cpp/noexcept.h" 3 | 4 | namespace YAML { 5 | 6 | // These destructors are defined out-of-line so the vtable is only emitted once. 7 | Exception::~Exception() YAML_CPP_NOEXCEPT = default; 8 | ParserException::~ParserException() YAML_CPP_NOEXCEPT = default; 9 | RepresentationException::~RepresentationException() YAML_CPP_NOEXCEPT = default; 10 | InvalidScalar::~InvalidScalar() YAML_CPP_NOEXCEPT = default; 11 | KeyNotFound::~KeyNotFound() YAML_CPP_NOEXCEPT = default; 12 | InvalidNode::~InvalidNode() YAML_CPP_NOEXCEPT = default; 13 | BadConversion::~BadConversion() YAML_CPP_NOEXCEPT = default; 14 | BadDereference::~BadDereference() YAML_CPP_NOEXCEPT = default; 15 | BadSubscript::~BadSubscript() YAML_CPP_NOEXCEPT = default; 16 | BadPushback::~BadPushback() YAML_CPP_NOEXCEPT = default; 17 | BadInsert::~BadInsert() YAML_CPP_NOEXCEPT = default; 18 | EmitterException::~EmitterException() YAML_CPP_NOEXCEPT = default; 19 | BadFile::~BadFile() YAML_CPP_NOEXCEPT = default; 20 | } // namespace YAML 21 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/indentation.h: -------------------------------------------------------------------------------- 1 | #ifndef INDENTATION_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define INDENTATION_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | #include 12 | 13 | #include "yaml-cpp/ostream_wrapper.h" 14 | 15 | namespace YAML { 16 | struct Indentation { 17 | Indentation(std::size_t n_) : n(n_) {} 18 | std::size_t n; 19 | }; 20 | 21 | inline ostream_wrapper& operator<<(ostream_wrapper& out, 22 | const Indentation& indent) { 23 | for (std::size_t i = 0; i < indent.n; i++) 24 | out << ' '; 25 | return out; 26 | } 27 | 28 | struct IndentTo { 29 | IndentTo(std::size_t n_) : n(n_) {} 30 | std::size_t n; 31 | }; 32 | 33 | inline ostream_wrapper& operator<<(ostream_wrapper& out, 34 | const IndentTo& indent) { 35 | while (out.col() < indent.n) 36 | out << ' '; 37 | return out; 38 | } 39 | } 40 | 41 | #endif // INDENTATION_H_62B23520_7C8E_11DE_8A39_0800200C9A66 42 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/memory.cpp: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/node/detail/memory.h" 2 | #include "yaml-cpp/node/detail/node.h" // IWYU pragma: keep 3 | #include "yaml-cpp/node/ptr.h" 4 | 5 | namespace YAML { 6 | namespace detail { 7 | 8 | void memory_holder::merge(memory_holder& rhs) { 9 | if (m_pMemory == rhs.m_pMemory) 10 | return; 11 | 12 | m_pMemory->merge(*rhs.m_pMemory); 13 | rhs.m_pMemory = m_pMemory; 14 | } 15 | 16 | node& memory::create_node() { 17 | shared_node pNode(new node); 18 | m_nodes.insert(pNode); 19 | return *pNode; 20 | } 21 | 22 | void memory::merge(const memory& rhs) { 23 | m_nodes.insert(rhs.m_nodes.begin(), rhs.m_nodes.end()); 24 | } 25 | } // namespace detail 26 | } // namespace YAML 27 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/node.cpp: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/node/node.h" 2 | #include "nodebuilder.h" 3 | #include "nodeevents.h" 4 | 5 | namespace YAML { 6 | Node Clone(const Node& node) { 7 | NodeEvents events(node); 8 | NodeBuilder builder; 9 | events.Emit(builder); 10 | return builder.Root(); 11 | } 12 | } // namespace YAML 13 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/nodeevents.h: -------------------------------------------------------------------------------- 1 | #ifndef NODE_NODEEVENTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define NODE_NODEEVENTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | #include 12 | 13 | #include "yaml-cpp/anchor.h" 14 | #include "yaml-cpp/node/ptr.h" 15 | 16 | namespace YAML { 17 | namespace detail { 18 | class node; 19 | } // namespace detail 20 | } // namespace YAML 21 | 22 | namespace YAML { 23 | class EventHandler; 24 | class Node; 25 | 26 | class NodeEvents { 27 | public: 28 | explicit NodeEvents(const Node& node); 29 | NodeEvents(const NodeEvents&) = delete; 30 | NodeEvents(NodeEvents&&) = delete; 31 | NodeEvents& operator=(const NodeEvents&) = delete; 32 | NodeEvents& operator=(NodeEvents&&) = delete; 33 | 34 | void Emit(EventHandler& handler); 35 | 36 | private: 37 | class AliasManager { 38 | public: 39 | AliasManager() : m_anchorByIdentity{}, m_curAnchor(0) {} 40 | 41 | void RegisterReference(const detail::node& node); 42 | anchor_t LookupAnchor(const detail::node& node) const; 43 | 44 | private: 45 | anchor_t _CreateNewAnchor() { return ++m_curAnchor; } 46 | 47 | private: 48 | using AnchorByIdentity = std::map; 49 | AnchorByIdentity m_anchorByIdentity; 50 | 51 | anchor_t m_curAnchor; 52 | }; 53 | 54 | void Setup(const detail::node& node); 55 | void Emit(const detail::node& node, EventHandler& handler, 56 | AliasManager& am) const; 57 | bool IsAliased(const detail::node& node) const; 58 | 59 | private: 60 | detail::shared_memory_holder m_pMemory; 61 | detail::node* m_root; 62 | 63 | using RefCount = std::map; 64 | RefCount m_refCount; 65 | }; 66 | } // namespace YAML 67 | 68 | #endif // NODE_NODEEVENTS_H_62B23520_7C8E_11DE_8A39_0800200C9A66 69 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/null.cpp: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/null.h" 2 | 3 | namespace YAML { 4 | _Null Null; 5 | 6 | bool IsNullString(const std::string& str) { 7 | return str.empty() || str == "~" || str == "null" || str == "Null" || 8 | str == "NULL"; 9 | } 10 | } // namespace YAML 11 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/ostream_wrapper.cpp: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/ostream_wrapper.h" 2 | 3 | #include 4 | #include 5 | #include 6 | 7 | namespace YAML { 8 | ostream_wrapper::ostream_wrapper() 9 | : m_buffer(1, '\0'), 10 | m_pStream(nullptr), 11 | m_pos(0), 12 | m_row(0), 13 | m_col(0), 14 | m_comment(false) {} 15 | 16 | ostream_wrapper::ostream_wrapper(std::ostream& stream) 17 | : m_buffer{}, 18 | m_pStream(&stream), 19 | m_pos(0), 20 | m_row(0), 21 | m_col(0), 22 | m_comment(false) {} 23 | 24 | ostream_wrapper::~ostream_wrapper() = default; 25 | 26 | void ostream_wrapper::write(const std::string& str) { 27 | if (m_pStream) { 28 | m_pStream->write(str.c_str(), str.size()); 29 | } else { 30 | m_buffer.resize(std::max(m_buffer.size(), m_pos + str.size() + 1)); 31 | std::copy(str.begin(), str.end(), m_buffer.begin() + m_pos); 32 | } 33 | 34 | for (char ch : str) { 35 | update_pos(ch); 36 | } 37 | } 38 | 39 | void ostream_wrapper::write(const char* str, std::size_t size) { 40 | if (m_pStream) { 41 | m_pStream->write(str, size); 42 | } else { 43 | m_buffer.resize(std::max(m_buffer.size(), m_pos + size + 1)); 44 | std::copy(str, str + size, m_buffer.begin() + m_pos); 45 | } 46 | 47 | for (std::size_t i = 0; i < size; i++) { 48 | update_pos(str[i]); 49 | } 50 | } 51 | 52 | void ostream_wrapper::update_pos(char ch) { 53 | m_pos++; 54 | m_col++; 55 | 56 | if (ch == '\n') { 57 | m_row++; 58 | m_col = 0; 59 | m_comment = false; 60 | } 61 | } 62 | } // namespace YAML 63 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/parse.cpp: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/node/parse.h" 2 | 3 | #include 4 | #include 5 | 6 | #include "nodebuilder.h" 7 | #include "yaml-cpp/node/impl.h" 8 | #include "yaml-cpp/node/node.h" 9 | #include "yaml-cpp/parser.h" 10 | 11 | namespace YAML { 12 | Node Load(const std::string& input) { 13 | std::stringstream stream(input); 14 | return Load(stream); 15 | } 16 | 17 | Node Load(const char* input) { 18 | std::stringstream stream(input); 19 | return Load(stream); 20 | } 21 | 22 | Node Load(std::istream& input) { 23 | Parser parser(input); 24 | NodeBuilder builder; 25 | if (!parser.HandleNextDocument(builder)) { 26 | return Node(); 27 | } 28 | 29 | return builder.Root(); 30 | } 31 | 32 | Node LoadFile(const std::string& filename) { 33 | std::ifstream fin(filename); 34 | if (!fin) { 35 | throw BadFile(filename); 36 | } 37 | return Load(fin); 38 | } 39 | 40 | std::vector LoadAll(const std::string& input) { 41 | std::stringstream stream(input); 42 | return LoadAll(stream); 43 | } 44 | 45 | std::vector LoadAll(const char* input) { 46 | std::stringstream stream(input); 47 | return LoadAll(stream); 48 | } 49 | 50 | std::vector LoadAll(std::istream& input) { 51 | std::vector docs; 52 | 53 | Parser parser(input); 54 | while (true) { 55 | NodeBuilder builder; 56 | if (!parser.HandleNextDocument(builder)) { 57 | break; 58 | } 59 | docs.push_back(builder.Root()); 60 | } 61 | 62 | return docs; 63 | } 64 | 65 | std::vector LoadAllFromFile(const std::string& filename) { 66 | std::ifstream fin(filename); 67 | if (!fin) { 68 | throw BadFile(filename); 69 | } 70 | return LoadAll(fin); 71 | } 72 | } // namespace YAML 73 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/ptr_vector.h: -------------------------------------------------------------------------------- 1 | #ifndef PTR_VECTOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define PTR_VECTOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | #include 12 | #include 13 | #include 14 | 15 | namespace YAML { 16 | 17 | // TODO: This class is no longer needed 18 | template 19 | class ptr_vector { 20 | public: 21 | ptr_vector() : m_data{} {} 22 | ptr_vector(const ptr_vector&) = delete; 23 | ptr_vector(ptr_vector&&) = default; 24 | ptr_vector& operator=(const ptr_vector&) = delete; 25 | ptr_vector& operator=(ptr_vector&&) = default; 26 | 27 | void clear() { m_data.clear(); } 28 | 29 | std::size_t size() const { return m_data.size(); } 30 | bool empty() const { return m_data.empty(); } 31 | 32 | void push_back(std::unique_ptr&& t) { m_data.push_back(std::move(t)); } 33 | T& operator[](std::size_t i) { return *m_data[i]; } 34 | const T& operator[](std::size_t i) const { return *m_data[i]; } 35 | 36 | T& back() { return *(m_data.back().get()); } 37 | 38 | const T& back() const { return *(m_data.back().get()); } 39 | 40 | private: 41 | std::vector> m_data; 42 | }; 43 | } // namespace YAML 44 | 45 | #endif // PTR_VECTOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66 46 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/regex_yaml.cpp: -------------------------------------------------------------------------------- 1 | #include "regex_yaml.h" 2 | 3 | namespace YAML { 4 | // constructors 5 | 6 | RegEx::RegEx(REGEX_OP op) : m_op(op), m_a(0), m_z(0), m_params{} {} 7 | RegEx::RegEx() : RegEx(REGEX_EMPTY) {} 8 | 9 | RegEx::RegEx(char ch) : m_op(REGEX_MATCH), m_a(ch), m_z(0), m_params{} {} 10 | 11 | RegEx::RegEx(char a, char z) : m_op(REGEX_RANGE), m_a(a), m_z(z), m_params{} {} 12 | 13 | RegEx::RegEx(const std::string& str, REGEX_OP op) 14 | : m_op(op), m_a(0), m_z(0), m_params(str.begin(), str.end()) {} 15 | 16 | // combination constructors 17 | RegEx operator!(const RegEx& ex) { 18 | RegEx ret(REGEX_NOT); 19 | ret.m_params.push_back(ex); 20 | return ret; 21 | } 22 | 23 | RegEx operator|(const RegEx& ex1, const RegEx& ex2) { 24 | RegEx ret(REGEX_OR); 25 | ret.m_params.push_back(ex1); 26 | ret.m_params.push_back(ex2); 27 | return ret; 28 | } 29 | 30 | RegEx operator&(const RegEx& ex1, const RegEx& ex2) { 31 | RegEx ret(REGEX_AND); 32 | ret.m_params.push_back(ex1); 33 | ret.m_params.push_back(ex2); 34 | return ret; 35 | } 36 | 37 | RegEx operator+(const RegEx& ex1, const RegEx& ex2) { 38 | RegEx ret(REGEX_SEQ); 39 | ret.m_params.push_back(ex1); 40 | ret.m_params.push_back(ex2); 41 | return ret; 42 | } 43 | } // namespace YAML 44 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/scantag.cpp: -------------------------------------------------------------------------------- 1 | #include "exp.h" 2 | #include "regex_yaml.h" 3 | #include "regeximpl.h" 4 | #include "stream.h" 5 | #include "yaml-cpp/exceptions.h" // IWYU pragma: keep 6 | #include "yaml-cpp/mark.h" 7 | 8 | namespace YAML { 9 | const std::string ScanVerbatimTag(Stream& INPUT) { 10 | std::string tag; 11 | 12 | // eat the start character 13 | INPUT.get(); 14 | 15 | while (INPUT) { 16 | if (INPUT.peek() == Keys::VerbatimTagEnd) { 17 | // eat the end character 18 | INPUT.get(); 19 | return tag; 20 | } 21 | 22 | int n = Exp::URI().Match(INPUT); 23 | if (n <= 0) 24 | break; 25 | 26 | tag += INPUT.get(n); 27 | } 28 | 29 | throw ParserException(INPUT.mark(), ErrorMsg::END_OF_VERBATIM_TAG); 30 | } 31 | 32 | const std::string ScanTagHandle(Stream& INPUT, bool& canBeHandle) { 33 | std::string tag; 34 | canBeHandle = true; 35 | Mark firstNonWordChar; 36 | 37 | while (INPUT) { 38 | if (INPUT.peek() == Keys::Tag) { 39 | if (!canBeHandle) 40 | throw ParserException(firstNonWordChar, ErrorMsg::CHAR_IN_TAG_HANDLE); 41 | break; 42 | } 43 | 44 | int n = 0; 45 | if (canBeHandle) { 46 | n = Exp::Word().Match(INPUT); 47 | if (n <= 0) { 48 | canBeHandle = false; 49 | firstNonWordChar = INPUT.mark(); 50 | } 51 | } 52 | 53 | if (!canBeHandle) 54 | n = Exp::Tag().Match(INPUT); 55 | 56 | if (n <= 0) 57 | break; 58 | 59 | tag += INPUT.get(n); 60 | } 61 | 62 | return tag; 63 | } 64 | 65 | const std::string ScanTagSuffix(Stream& INPUT) { 66 | std::string tag; 67 | 68 | while (INPUT) { 69 | int n = Exp::Tag().Match(INPUT); 70 | if (n <= 0) 71 | break; 72 | 73 | tag += INPUT.get(n); 74 | } 75 | 76 | if (tag.empty()) 77 | throw ParserException(INPUT.mark(), ErrorMsg::TAG_WITH_NO_SUFFIX); 78 | 79 | return tag; 80 | } 81 | } // namespace YAML 82 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/scantag.h: -------------------------------------------------------------------------------- 1 | #ifndef SCANTAG_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define SCANTAG_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | #include "stream.h" 12 | 13 | namespace YAML { 14 | const std::string ScanVerbatimTag(Stream& INPUT); 15 | const std::string ScanTagHandle(Stream& INPUT, bool& canBeHandle); 16 | const std::string ScanTagSuffix(Stream& INPUT); 17 | } 18 | 19 | #endif // SCANTAG_H_62B23520_7C8E_11DE_8A39_0800200C9A66 20 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/streamcharsource.h: -------------------------------------------------------------------------------- 1 | #ifndef STREAMCHARSOURCE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define STREAMCHARSOURCE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include "yaml-cpp/noexcept.h" 11 | #include "stream.h" 12 | #include 13 | 14 | namespace YAML { 15 | 16 | class StreamCharSource { 17 | public: 18 | StreamCharSource(const Stream& stream) : m_offset(0), m_stream(stream) {} 19 | StreamCharSource(const StreamCharSource& source) = default; 20 | StreamCharSource(StreamCharSource&&) YAML_CPP_NOEXCEPT = default; 21 | StreamCharSource& operator=(const StreamCharSource&) = delete; 22 | StreamCharSource& operator=(StreamCharSource&&) = delete; 23 | ~StreamCharSource() = default; 24 | 25 | operator bool() const; 26 | char operator[](std::size_t i) const { return m_stream.CharAt(m_offset + i); } 27 | bool operator!() const { return !static_cast(*this); } 28 | 29 | const StreamCharSource operator+(int i) const; 30 | 31 | private: 32 | std::size_t m_offset; 33 | const Stream& m_stream; 34 | }; 35 | 36 | inline StreamCharSource::operator bool() const { 37 | return m_stream.ReadAheadTo(m_offset); 38 | } 39 | 40 | inline const StreamCharSource StreamCharSource::operator+(int i) const { 41 | StreamCharSource source(*this); 42 | if (static_cast(source.m_offset) + i >= 0) 43 | source.m_offset += static_cast(i); 44 | else 45 | source.m_offset = 0; 46 | return source; 47 | } 48 | } // namespace YAML 49 | 50 | #endif // STREAMCHARSOURCE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 51 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/stringsource.h: -------------------------------------------------------------------------------- 1 | #ifndef STRINGSOURCE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define STRINGSOURCE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | 12 | namespace YAML { 13 | class StringCharSource { 14 | public: 15 | StringCharSource(const char* str, std::size_t size) 16 | : m_str(str), m_size(size), m_offset(0) {} 17 | 18 | operator bool() const { return m_offset < m_size; } 19 | char operator[](std::size_t i) const { return m_str[m_offset + i]; } 20 | bool operator!() const { return !static_cast(*this); } 21 | 22 | const StringCharSource operator+(int i) const { 23 | StringCharSource source(*this); 24 | if (static_cast(source.m_offset) + i >= 0) 25 | source.m_offset += i; 26 | else 27 | source.m_offset = 0; 28 | return source; 29 | } 30 | 31 | StringCharSource& operator++() { 32 | ++m_offset; 33 | return *this; 34 | } 35 | 36 | StringCharSource& operator+=(std::size_t offset) { 37 | m_offset += offset; 38 | return *this; 39 | } 40 | 41 | private: 42 | const char* m_str; 43 | std::size_t m_size; 44 | std::size_t m_offset; 45 | }; 46 | } 47 | 48 | #endif // STRINGSOURCE_H_62B23520_7C8E_11DE_8A39_0800200C9A66 49 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/tag.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #include "directives.h" // IWYU pragma: keep 5 | #include "tag.h" 6 | #include "token.h" 7 | 8 | namespace YAML { 9 | Tag::Tag(const Token& token) 10 | : type(static_cast(token.data)), handle{}, value{} { 11 | switch (type) { 12 | case VERBATIM: 13 | value = token.value; 14 | break; 15 | case PRIMARY_HANDLE: 16 | value = token.value; 17 | break; 18 | case SECONDARY_HANDLE: 19 | value = token.value; 20 | break; 21 | case NAMED_HANDLE: 22 | handle = token.value; 23 | value = token.params[0]; 24 | break; 25 | case NON_SPECIFIC: 26 | break; 27 | default: 28 | assert(false); 29 | } 30 | } 31 | 32 | const std::string Tag::Translate(const Directives& directives) { 33 | switch (type) { 34 | case VERBATIM: 35 | return value; 36 | case PRIMARY_HANDLE: 37 | return directives.TranslateTagHandle("!") + value; 38 | case SECONDARY_HANDLE: 39 | return directives.TranslateTagHandle("!!") + value; 40 | case NAMED_HANDLE: 41 | return directives.TranslateTagHandle("!" + handle + "!") + value; 42 | case NON_SPECIFIC: 43 | // TODO: 44 | return "!"; 45 | default: 46 | assert(false); 47 | } 48 | throw std::runtime_error("yaml-cpp: internal error, bad tag type"); 49 | } 50 | } // namespace YAML 51 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/tag.h: -------------------------------------------------------------------------------- 1 | #ifndef TAG_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define TAG_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include 11 | 12 | namespace YAML { 13 | struct Directives; 14 | struct Token; 15 | 16 | struct Tag { 17 | enum TYPE { 18 | VERBATIM, 19 | PRIMARY_HANDLE, 20 | SECONDARY_HANDLE, 21 | NAMED_HANDLE, 22 | NON_SPECIFIC 23 | }; 24 | 25 | Tag(const Token& token); 26 | const std::string Translate(const Directives& directives); 27 | 28 | TYPE type; 29 | std::string handle, value; 30 | }; 31 | } 32 | 33 | #endif // TAG_H_62B23520_7C8E_11DE_8A39_0800200C9A66 34 | -------------------------------------------------------------------------------- /external/yaml-cpp/src/token.h: -------------------------------------------------------------------------------- 1 | #ifndef TOKEN_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 | #define TOKEN_H_62B23520_7C8E_11DE_8A39_0800200C9A66 3 | 4 | #if defined(_MSC_VER) || \ 5 | (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 | (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 7 | #pragma once 8 | #endif 9 | 10 | #include "yaml-cpp/mark.h" 11 | #include 12 | #include 13 | #include 14 | 15 | namespace YAML { 16 | const std::string TokenNames[] = { 17 | "DIRECTIVE", "DOC_START", "DOC_END", "BLOCK_SEQ_START", 18 | "BLOCK_MAP_START", "BLOCK_SEQ_END", "BLOCK_MAP_END", "BLOCK_ENTRY", 19 | "FLOW_SEQ_START", "FLOW_MAP_START", "FLOW_SEQ_END", "FLOW_MAP_END", 20 | "FLOW_MAP_COMPACT", "FLOW_ENTRY", "KEY", "VALUE", 21 | "ANCHOR", "ALIAS", "TAG", "SCALAR"}; 22 | 23 | struct Token { 24 | // enums 25 | enum STATUS { VALID, INVALID, UNVERIFIED }; 26 | enum TYPE { 27 | DIRECTIVE, 28 | DOC_START, 29 | DOC_END, 30 | BLOCK_SEQ_START, 31 | BLOCK_MAP_START, 32 | BLOCK_SEQ_END, 33 | BLOCK_MAP_END, 34 | BLOCK_ENTRY, 35 | FLOW_SEQ_START, 36 | FLOW_MAP_START, 37 | FLOW_SEQ_END, 38 | FLOW_MAP_END, 39 | FLOW_MAP_COMPACT, 40 | FLOW_ENTRY, 41 | KEY, 42 | VALUE, 43 | ANCHOR, 44 | ALIAS, 45 | TAG, 46 | PLAIN_SCALAR, 47 | NON_PLAIN_SCALAR 48 | }; 49 | 50 | // data 51 | Token(TYPE type_, const Mark& mark_) 52 | : status(VALID), type(type_), mark(mark_), value{}, params{}, data(0) {} 53 | 54 | friend std::ostream& operator<<(std::ostream& out, const Token& token) { 55 | out << TokenNames[token.type] << std::string(": ") << token.value; 56 | for (const std::string& param : token.params) 57 | out << std::string(" ") << param; 58 | return out; 59 | } 60 | 61 | STATUS status; 62 | TYPE type; 63 | Mark mark; 64 | std::string value; 65 | std::vector params; 66 | int data; 67 | }; 68 | } // namespace YAML 69 | 70 | #endif // TOKEN_H_62B23520_7C8E_11DE_8A39_0800200C9A66 71 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/BUILD.bazel: -------------------------------------------------------------------------------- 1 | cc_test( 2 | name = "test", 3 | srcs = glob([ 4 | "*.cpp", 5 | "*.h", 6 | "integrations/*.cpp", 7 | "node/*.cpp", 8 | ]), 9 | deps = [ 10 | "//:yaml-cpp", 11 | "//:yaml-cpp_internal", 12 | "@com_google_googletest//:gtest_main", 13 | ], 14 | ) 15 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | find_package(Threads REQUIRED) 2 | 3 | set(gtest_force_shared_crt ON CACHE BOOL "" FORCE) 4 | set(BUILD_MOCK ON CACHE BOOL "" FORCE) 5 | set(CMAKE_POLICY_DEFAULT_CMP0048 NEW) 6 | 7 | add_subdirectory( 8 | "${CMAKE_CURRENT_SOURCE_DIR}/gtest-1.10.0" 9 | "${CMAKE_CURRENT_BINARY_DIR}/prefix") 10 | 11 | include_directories(SYSTEM "${CMAKE_CURRENT_SOURCE_DIR}/gtest-1.10.0/googletest/include") 12 | 13 | set(test-new-api-pattern "new-api/*.cpp") 14 | set(test-source-pattern "*.cpp" "integration/*.cpp" "node/*.cpp") 15 | if (CMAKE_VERSION VERSION_GREATER 3.11) 16 | list(INSERT test-new-api-pattern 0 CONFIGURE_DEPENDS) 17 | list(INSERT test-source-pattern 0 CONFIGURE_DEPENDS) 18 | endif() 19 | 20 | file(GLOB test-new-api-sources ${test-new-api-pattern}) 21 | file(GLOB test-sources ${test-source-pattern}) 22 | 23 | add_executable(yaml-cpp-tests "") 24 | target_sources(yaml-cpp-tests 25 | PRIVATE 26 | ${test-new-api-sources} 27 | ${test-sources}) 28 | target_include_directories(yaml-cpp-tests 29 | PRIVATE 30 | ${CMAKE_CURRENT_SOURCE_DIR}/integration 31 | ${CMAKE_CURRENT_SOURCE_DIR} 32 | ${PROJECT_SOURCE_DIR}/src) 33 | target_compile_options(yaml-cpp-tests 34 | PRIVATE 35 | $<$:-Wno-c99-extensions -Wno-variadic-macros -Wno-sign-compare> 36 | $<$:-Wno-variadic-macros -Wno-sign-compare>) 37 | target_link_libraries(yaml-cpp-tests 38 | PRIVATE 39 | Threads::Threads 40 | yaml-cpp 41 | gmock) 42 | 43 | set_property(TARGET yaml-cpp-tests PROPERTY CXX_STANDARD_REQUIRED ON) 44 | if (NOT DEFINED CMAKE_CXX_STANDARD) 45 | set_target_properties(yaml-cpp-tests PROPERTIES CXX_STANDARD 11) 46 | endif() 47 | 48 | 49 | add_test(yaml-cpp::test yaml-cpp-tests) 50 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/binary_test.cpp: -------------------------------------------------------------------------------- 1 | #include "gtest/gtest.h" 2 | #include 3 | 4 | TEST(BinaryTest, DecodingSimple) { 5 | std::string input{90, 71, 86, 104, 90, 71, 74, 108, 90, 87, 89, 61}; 6 | const std::vector &result = YAML::DecodeBase64(input); 7 | EXPECT_EQ(std::string(result.begin(), result.end()), "deadbeef"); 8 | } 9 | 10 | TEST(BinaryTest, DecodingNoCrashOnNegative) { 11 | std::string input{-58, -1, -99, 109}; 12 | const std::vector &result = YAML::DecodeBase64(input); 13 | EXPECT_TRUE(result.empty()); 14 | } 15 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/.clang-format: -------------------------------------------------------------------------------- 1 | # Run manually to reformat a file: 2 | # clang-format -i --style=file 3 | Language: Cpp 4 | BasedOnStyle: Google 5 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/.gitignore: -------------------------------------------------------------------------------- 1 | # Ignore CI build directory 2 | build/ 3 | xcuserdata 4 | cmake-build-debug/ 5 | .idea/ 6 | bazel-bin 7 | bazel-genfiles 8 | bazel-googletest 9 | bazel-out 10 | bazel-testlogs 11 | # python 12 | *.pyc 13 | 14 | # Visual Studio files 15 | .vs 16 | *.sdf 17 | *.opensdf 18 | *.VC.opendb 19 | *.suo 20 | *.user 21 | _ReSharper.Caches/ 22 | Win32-Debug/ 23 | Win32-Release/ 24 | x64-Debug/ 25 | x64-Release/ 26 | 27 | # Ignore autoconf / automake files 28 | Makefile.in 29 | aclocal.m4 30 | configure 31 | build-aux/ 32 | autom4te.cache/ 33 | googletest/m4/libtool.m4 34 | googletest/m4/ltoptions.m4 35 | googletest/m4/ltsugar.m4 36 | googletest/m4/ltversion.m4 37 | googletest/m4/lt~obsolete.m4 38 | googlemock/m4 39 | 40 | # Ignore generated directories. 41 | googlemock/fused-src/ 42 | googletest/fused-src/ 43 | 44 | # macOS files 45 | .DS_Store 46 | googletest/.DS_Store 47 | googletest/xcode/.DS_Store 48 | 49 | # Ignore cmake generated directories and files. 50 | CMakeFiles 51 | CTestTestfile.cmake 52 | Makefile 53 | cmake_install.cmake 54 | googlemock/CMakeFiles 55 | googlemock/CTestTestfile.cmake 56 | googlemock/Makefile 57 | googlemock/cmake_install.cmake 58 | googlemock/gtest 59 | /bin 60 | /googlemock/gmock.dir 61 | /googlemock/gmock_main.dir 62 | /googlemock/RUN_TESTS.vcxproj.filters 63 | /googlemock/RUN_TESTS.vcxproj 64 | /googlemock/INSTALL.vcxproj.filters 65 | /googlemock/INSTALL.vcxproj 66 | /googlemock/gmock_main.vcxproj.filters 67 | /googlemock/gmock_main.vcxproj 68 | /googlemock/gmock.vcxproj.filters 69 | /googlemock/gmock.vcxproj 70 | /googlemock/gmock.sln 71 | /googlemock/ALL_BUILD.vcxproj.filters 72 | /googlemock/ALL_BUILD.vcxproj 73 | /lib 74 | /Win32 75 | /ZERO_CHECK.vcxproj.filters 76 | /ZERO_CHECK.vcxproj 77 | /RUN_TESTS.vcxproj.filters 78 | /RUN_TESTS.vcxproj 79 | /INSTALL.vcxproj.filters 80 | /INSTALL.vcxproj 81 | /googletest-distribution.sln 82 | /CMakeCache.txt 83 | /ALL_BUILD.vcxproj.filters 84 | /ALL_BUILD.vcxproj 85 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Note: CMake support is community-based. The maintainers do not use CMake 2 | # internally. 3 | 4 | cmake_minimum_required(VERSION 2.9) 5 | 6 | if (POLICY CMP0048) 7 | cmake_policy(SET CMP0048 NEW) 8 | endif (POLICY CMP0048) 9 | 10 | project(googletest-distribution) 11 | set(GOOGLETEST_VERSION 1.10.0) 12 | 13 | if (CMAKE_VERSION VERSION_LESS "3.1") 14 | add_definitions(-std=c++11) 15 | else() 16 | set(CMAKE_CXX_STANDARD 11) 17 | set(CMAKE_CXX_STANDARD_REQUIRED ON) 18 | if(NOT CYGWIN) 19 | set(CMAKE_CXX_EXTENSIONS OFF) 20 | endif() 21 | endif() 22 | 23 | enable_testing() 24 | 25 | include(CMakeDependentOption) 26 | include(GNUInstallDirs) 27 | 28 | #Note that googlemock target already builds googletest 29 | option(BUILD_GMOCK "Builds the googlemock subproject" ON) 30 | option(INSTALL_GTEST "Enable installation of googletest. (Projects embedding googletest may want to turn this OFF.)" ON) 31 | 32 | if(BUILD_GMOCK) 33 | add_subdirectory( googlemock ) 34 | else() 35 | add_subdirectory( googletest ) 36 | endif() 37 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2008, Google Inc. 2 | All rights reserved. 3 | 4 | Redistribution and use in source and binary forms, with or without 5 | modification, are permitted provided that the following conditions are 6 | met: 7 | 8 | * Redistributions of source code must retain the above copyright 9 | notice, this list of conditions and the following disclaimer. 10 | * Redistributions in binary form must reproduce the above 11 | copyright notice, this list of conditions and the following disclaimer 12 | in the documentation and/or other materials provided with the 13 | distribution. 14 | * Neither the name of Google Inc. nor the names of its 15 | contributors may be used to endorse or promote products derived from 16 | this software without specific prior written permission. 17 | 18 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/WORKSPACE: -------------------------------------------------------------------------------- 1 | workspace(name = "com_google_googletest") 2 | 3 | load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") 4 | 5 | # Abseil 6 | http_archive( 7 | name = "com_google_absl", 8 | urls = ["https://github.com/abseil/abseil-cpp/archive/master.zip"], 9 | strip_prefix = "abseil-cpp-master", 10 | ) 11 | 12 | http_archive( 13 | name = "rules_cc", 14 | strip_prefix = "rules_cc-master", 15 | urls = ["https://github.com/bazelbuild/rules_cc/archive/master.zip"], 16 | ) 17 | 18 | http_archive( 19 | name = "rules_python", 20 | strip_prefix = "rules_python-master", 21 | urls = ["https://github.com/bazelbuild/rules_python/archive/master.zip"], 22 | ) 23 | 24 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/ci/build-linux-bazel.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright 2017 Google Inc. 3 | # All Rights Reserved. 4 | # 5 | # 6 | # Redistribution and use in source and binary forms, with or without 7 | # modification, are permitted provided that the following conditions are 8 | # met: 9 | # 10 | # * Redistributions of source code must retain the above copyright 11 | # notice, this list of conditions and the following disclaimer. 12 | # * Redistributions in binary form must reproduce the above 13 | # copyright notice, this list of conditions and the following disclaimer 14 | # in the documentation and/or other materials provided with the 15 | # distribution. 16 | # * Neither the name of Google Inc. nor the names of its 17 | # contributors may be used to endorse or promote products derived from 18 | # this software without specific prior written permission. 19 | # 20 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 21 | # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 22 | # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 23 | # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 24 | # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 25 | # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 26 | # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 27 | # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 28 | # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 29 | # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 30 | # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 | 32 | set -e 33 | 34 | bazel version 35 | bazel build --curses=no //...:all 36 | bazel test --curses=no //...:all 37 | bazel test --curses=no //...:all --define absl=1 38 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/ci/build-platformio.sh: -------------------------------------------------------------------------------- 1 | # run PlatformIO builds 2 | platformio run 3 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/ci/env-linux.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright 2017 Google Inc. 3 | # All Rights Reserved. 4 | # 5 | # 6 | # Redistribution and use in source and binary forms, with or without 7 | # modification, are permitted provided that the following conditions are 8 | # met: 9 | # 10 | # * Redistributions of source code must retain the above copyright 11 | # notice, this list of conditions and the following disclaimer. 12 | # * Redistributions in binary form must reproduce the above 13 | # copyright notice, this list of conditions and the following disclaimer 14 | # in the documentation and/or other materials provided with the 15 | # distribution. 16 | # * Neither the name of Google Inc. nor the names of its 17 | # contributors may be used to endorse or promote products derived from 18 | # this software without specific prior written permission. 19 | # 20 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 21 | # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 22 | # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 23 | # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 24 | # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 25 | # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 26 | # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 27 | # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 28 | # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 29 | # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 30 | # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 | 32 | # 33 | # This file should be sourced, and not executed as a standalone script. 34 | # 35 | 36 | # TODO() - we can check if this is being sourced using $BASH_VERSION and $BASH_SOURCE[0] != ${0}. 37 | 38 | if [ "${TRAVIS_OS_NAME}" = "linux" ]; then 39 | if [ "$CXX" = "g++" ]; then export CXX="g++-4.9" CC="gcc-4.9"; fi 40 | if [ "$CXX" = "clang++" ]; then export CXX="clang++-3.9" CC="clang-3.9"; fi 41 | fi 42 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/ci/env-osx.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright 2017 Google Inc. 3 | # All Rights Reserved. 4 | # 5 | # 6 | # Redistribution and use in source and binary forms, with or without 7 | # modification, are permitted provided that the following conditions are 8 | # met: 9 | # 10 | # * Redistributions of source code must retain the above copyright 11 | # notice, this list of conditions and the following disclaimer. 12 | # * Redistributions in binary form must reproduce the above 13 | # copyright notice, this list of conditions and the following disclaimer 14 | # in the documentation and/or other materials provided with the 15 | # distribution. 16 | # * Neither the name of Google Inc. nor the names of its 17 | # contributors may be used to endorse or promote products derived from 18 | # this software without specific prior written permission. 19 | # 20 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 21 | # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 22 | # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 23 | # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 24 | # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 25 | # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 26 | # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 27 | # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 28 | # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 29 | # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 30 | # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 | 32 | # 33 | # This file should be sourced, and not executed as a standalone script. 34 | # 35 | 36 | # TODO() - we can check if this is being sourced using $BASH_VERSION and $BASH_SOURCE[0] != ${0}. 37 | # 38 | 39 | if [ "${TRAVIS_OS_NAME}" = "osx" ]; then 40 | if [ "$CXX" = "clang++" ]; then 41 | # $PATH needs to be adjusted because the llvm tap doesn't install the 42 | # package to /usr/local/bin, etc, like the gcc tap does. 43 | # See: https://github.com/Homebrew/legacy-homebrew/issues/29733 44 | clang_version=3.9 45 | export PATH="/usr/local/opt/llvm@${clang_version}/bin:$PATH"; 46 | fi 47 | fi 48 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/ci/install-osx.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright 2017 Google Inc. 3 | # All Rights Reserved. 4 | # 5 | # 6 | # Redistribution and use in source and binary forms, with or without 7 | # modification, are permitted provided that the following conditions are 8 | # met: 9 | # 10 | # * Redistributions of source code must retain the above copyright 11 | # notice, this list of conditions and the following disclaimer. 12 | # * Redistributions in binary form must reproduce the above 13 | # copyright notice, this list of conditions and the following disclaimer 14 | # in the documentation and/or other materials provided with the 15 | # distribution. 16 | # * Neither the name of Google Inc. nor the names of its 17 | # contributors may be used to endorse or promote products derived from 18 | # this software without specific prior written permission. 19 | # 20 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 21 | # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 22 | # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 23 | # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 24 | # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 25 | # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 26 | # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 27 | # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 28 | # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 29 | # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 30 | # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 | 32 | set -eu 33 | 34 | if [ "${TRAVIS_OS_NAME}" != "osx" ]; then 35 | echo "Not a macOS build; skipping installation" 36 | exit 0 37 | fi 38 | 39 | brew update 40 | brew install ccache gcc@4.9 41 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/ci/install-platformio.sh: -------------------------------------------------------------------------------- 1 | # install PlatformIO 2 | sudo pip install -U platformio 3 | 4 | # update PlatformIO 5 | platformio update 6 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/ci/log-config.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | # Copyright 2017 Google Inc. 3 | # All Rights Reserved. 4 | # 5 | # 6 | # Redistribution and use in source and binary forms, with or without 7 | # modification, are permitted provided that the following conditions are 8 | # met: 9 | # 10 | # * Redistributions of source code must retain the above copyright 11 | # notice, this list of conditions and the following disclaimer. 12 | # * Redistributions in binary form must reproduce the above 13 | # copyright notice, this list of conditions and the following disclaimer 14 | # in the documentation and/or other materials provided with the 15 | # distribution. 16 | # * Neither the name of Google Inc. nor the names of its 17 | # contributors may be used to endorse or promote products derived from 18 | # this software without specific prior written permission. 19 | # 20 | # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 21 | # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 22 | # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 23 | # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 24 | # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 25 | # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 26 | # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 27 | # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 28 | # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 29 | # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 30 | # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 | 32 | set -e 33 | 34 | # ccache on OS X needs installation first 35 | # reset ccache statistics 36 | ccache --zero-stats 37 | 38 | echo PATH=${PATH} 39 | 40 | echo "Compiler configuration:" 41 | echo CXX=${CXX} 42 | echo CC=${CC} 43 | echo CXXFLAGS=${CXXFLAGS} 44 | 45 | echo "C++ compiler version:" 46 | ${CXX} --version || echo "${CXX} does not seem to support the --version flag" 47 | ${CXX} -v || echo "${CXX} does not seem to support the -v flag" 48 | 49 | echo "C compiler version:" 50 | ${CC} --version || echo "${CXX} does not seem to support the --version flag" 51 | ${CC} -v || echo "${CXX} does not seem to support the -v flag" 52 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/ci/travis.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env sh 2 | set -evx 3 | 4 | . ci/get-nprocessors.sh 5 | 6 | # if possible, ask for the precise number of processors, 7 | # otherwise take 2 processors as reasonable default; see 8 | # https://docs.travis-ci.com/user/speeding-up-the-build/#Makefile-optimization 9 | if [ -x /usr/bin/getconf ]; then 10 | NPROCESSORS=$(/usr/bin/getconf _NPROCESSORS_ONLN) 11 | else 12 | NPROCESSORS=2 13 | fi 14 | # as of 2017-09-04 Travis CI reports 32 processors, but GCC build 15 | # crashes if parallelized too much (maybe memory consumption problem), 16 | # so limit to 4 processors for the time being. 17 | if [ $NPROCESSORS -gt 4 ] ; then 18 | echo "$0:Note: Limiting processors to use by make from $NPROCESSORS to 4." 19 | NPROCESSORS=4 20 | fi 21 | # Tell make to use the processors. No preceding '-' required. 22 | MAKEFLAGS="j${NPROCESSORS}" 23 | export MAKEFLAGS 24 | 25 | env | sort 26 | 27 | # Set default values to OFF for these variables if not specified. 28 | : "${NO_EXCEPTION:=OFF}" 29 | : "${NO_RTTI:=OFF}" 30 | : "${COMPILER_IS_GNUCXX:=OFF}" 31 | 32 | mkdir build || true 33 | cd build 34 | cmake -Dgtest_build_samples=ON \ 35 | -Dgtest_build_tests=ON \ 36 | -Dgmock_build_tests=ON \ 37 | -Dcxx_no_exception=$NO_EXCEPTION \ 38 | -Dcxx_no_rtti=$NO_RTTI \ 39 | -DCMAKE_COMPILER_IS_GNUCXX=$COMPILER_IS_GNUCXX \ 40 | -DCMAKE_CXX_FLAGS=$CXX_FLAGS \ 41 | -DCMAKE_BUILD_TYPE=$BUILD_TYPE \ 42 | .. 43 | make 44 | CTEST_OUTPUT_ON_FAILURE=1 make test 45 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This file contains a list of people who've made non-trivial 2 | # contribution to the Google C++ Mocking Framework project. People 3 | # who commit code to the project are encouraged to add their names 4 | # here. Please keep the list sorted by first names. 5 | 6 | Benoit Sigoure 7 | Bogdan Piloca 8 | Chandler Carruth 9 | Dave MacLachlan 10 | David Anderson 11 | Dean Sturtevant 12 | Gene Volovich 13 | Hal Burch 14 | Jeffrey Yasskin 15 | Jim Keller 16 | Joe Walnes 17 | Jon Wray 18 | Keir Mierle 19 | Keith Ray 20 | Kostya Serebryany 21 | Lev Makhlis 22 | Manuel Klimek 23 | Mario Tanev 24 | Mark Paskin 25 | Markus Heule 26 | Matthew Simmons 27 | Mike Bland 28 | Neal Norwitz 29 | Nermin Ozkiranartli 30 | Owen Carlsen 31 | Paneendra Ba 32 | Paul Menage 33 | Piotr Kaminski 34 | Russ Rufer 35 | Sverre Sundsdal 36 | Takeshi Yoshino 37 | Vadim Berman 38 | Vlad Losev 39 | Wolfgang Klier 40 | Zhanyong Wan 41 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2008, Google Inc. 2 | All rights reserved. 3 | 4 | Redistribution and use in source and binary forms, with or without 5 | modification, are permitted provided that the following conditions are 6 | met: 7 | 8 | * Redistributions of source code must retain the above copyright 9 | notice, this list of conditions and the following disclaimer. 10 | * Redistributions in binary form must reproduce the above 11 | copyright notice, this list of conditions and the following disclaimer 12 | in the documentation and/or other materials provided with the 13 | distribution. 14 | * Neither the name of Google Inc. nor the names of its 15 | contributors may be used to endorse or promote products derived from 16 | this software without specific prior written permission. 17 | 18 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/README.md: -------------------------------------------------------------------------------- 1 | # Googletest Mocking (gMock) Framework 2 | 3 | ### Overview 4 | 5 | Google's framework for writing and using C++ mock classes. It can help you 6 | derive better designs of your system and write better tests. 7 | 8 | It is inspired by: 9 | 10 | * [jMock](http://www.jmock.org/), 11 | * [EasyMock](http://www.easymock.org/), and 12 | * [Hamcrest](http://code.google.com/p/hamcrest/), 13 | 14 | and designed with C++'s specifics in mind. 15 | 16 | gMock: 17 | 18 | - provides a declarative syntax for defining mocks, 19 | - can define partial (hybrid) mocks, which are a cross of real and mock 20 | objects, 21 | - handles functions of arbitrary types and overloaded functions, 22 | - comes with a rich set of matchers for validating function arguments, 23 | - uses an intuitive syntax for controlling the behavior of a mock, 24 | - does automatic verification of expectations (no record-and-replay needed), 25 | - allows arbitrary (partial) ordering constraints on function calls to be 26 | expressed, 27 | - lets a user extend it by defining new matchers and actions. 28 | - does not use exceptions, and 29 | - is easy to learn and use. 30 | 31 | Details and examples can be found here: 32 | 33 | * [gMock for Dummies](docs/for_dummies.md) 34 | * [Legacy gMock FAQ](docs/gmock_faq.md) 35 | * [gMock Cookbook](docs/cook_book.md) 36 | * [gMock Cheat Sheet](docs/cheat_sheet.md) 37 | 38 | Please note that code under scripts/generator/ is from the [cppclean 39 | project](http://code.google.com/p/cppclean/) and under the Apache 40 | License, which is different from Google Mock's license. 41 | 42 | Google Mock is a part of 43 | [Google Test C++ testing framework](http://github.com/google/googletest/) and a 44 | subject to the same requirements. 45 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/cmake/gmock.pc.in: -------------------------------------------------------------------------------- 1 | prefix=${pcfiledir}/../.. 2 | libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@ 3 | includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@ 4 | 5 | Name: gmock 6 | Description: GoogleMock (without main() function) 7 | Version: @PROJECT_VERSION@ 8 | URL: https://github.com/google/googletest 9 | Requires: gtest 10 | Libs: -L${libdir} -lgmock @CMAKE_THREAD_LIBS_INIT@ 11 | Cflags: -I${includedir} @GTEST_HAS_PTHREAD_MACRO@ @CMAKE_THREAD_LIBS_INIT@ 12 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/cmake/gmock_main.pc.in: -------------------------------------------------------------------------------- 1 | prefix=${pcfiledir}/../.. 2 | libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@ 3 | includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@ 4 | 5 | Name: gmock_main 6 | Description: GoogleMock (with main() function) 7 | Version: @PROJECT_VERSION@ 8 | URL: https://github.com/google/googletest 9 | Requires: gmock 10 | Libs: -L${libdir} -lgmock_main @CMAKE_THREAD_LIBS_INIT@ 11 | Cflags: -I${includedir} @GTEST_HAS_PTHREAD_MACRO@ @CMAKE_THREAD_LIBS_INIT@ 12 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/include/gmock/internal/custom/README.md: -------------------------------------------------------------------------------- 1 | # Customization Points 2 | 3 | The custom directory is an injection point for custom user configurations. 4 | 5 | ## Header `gmock-port.h` 6 | 7 | The following macros can be defined: 8 | 9 | ### Flag related macros: 10 | 11 | * `GMOCK_DECLARE_bool_(name)` 12 | * `GMOCK_DECLARE_int32_(name)` 13 | * `GMOCK_DECLARE_string_(name)` 14 | * `GMOCK_DEFINE_bool_(name, default_val, doc)` 15 | * `GMOCK_DEFINE_int32_(name, default_val, doc)` 16 | * `GMOCK_DEFINE_string_(name, default_val, doc)` 17 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/include/gmock/internal/custom/gmock-generated-actions.h: -------------------------------------------------------------------------------- 1 | // This file was GENERATED by command: 2 | // pump.py gmock-generated-actions.h.pump 3 | // DO NOT EDIT BY HAND!!! 4 | 5 | // GOOGLETEST_CM0002 DO NOT DELETE 6 | 7 | #ifndef GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_GENERATED_ACTIONS_H_ 8 | #define GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_GENERATED_ACTIONS_H_ 9 | 10 | #endif // GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_GENERATED_ACTIONS_H_ 11 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/include/gmock/internal/custom/gmock-generated-actions.h.pump: -------------------------------------------------------------------------------- 1 | $$ -*- mode: c++; -*- 2 | $$ This is a Pump source file. Please use Pump to convert 3 | $$ it to callback-actions.h. 4 | $$ 5 | $var max_callback_arity = 5 6 | $$}} This meta comment fixes auto-indentation in editors. 7 | 8 | // GOOGLETEST_CM0002 DO NOT DELETE 9 | #ifndef GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_GENERATED_ACTIONS_H_ 10 | #define GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_GENERATED_ACTIONS_H_ 11 | 12 | #endif // GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_GENERATED_ACTIONS_H_ 13 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/include/gmock/internal/custom/gmock-matchers.h: -------------------------------------------------------------------------------- 1 | // Copyright 2015, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // Injection point for custom user configurations. See README for details 31 | // 32 | // GOOGLETEST_CM0002 DO NOT DELETE 33 | 34 | #ifndef GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_MATCHERS_H_ 35 | #define GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_MATCHERS_H_ 36 | #endif // GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_MATCHERS_H_ 37 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/include/gmock/internal/custom/gmock-port.h: -------------------------------------------------------------------------------- 1 | // Copyright 2015, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // Injection point for custom user configurations. See README for details 31 | // 32 | // ** Custom implementation starts here ** 33 | 34 | // GOOGLETEST_CM0002 DO NOT DELETE 35 | 36 | #ifndef GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_PORT_H_ 37 | #define GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_PORT_H_ 38 | 39 | #endif // GMOCK_INCLUDE_GMOCK_INTERNAL_CUSTOM_GMOCK_PORT_H_ 40 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/scripts/generator/README: -------------------------------------------------------------------------------- 1 | 2 | The Google Mock class generator is an application that is part of cppclean. 3 | For more information about cppclean, visit http://code.google.com/p/cppclean/ 4 | 5 | The mock generator requires Python 2.3.5 or later. If you don't have Python 6 | installed on your system, you will also need to install it. You can download 7 | Python from: http://www.python.org/download/releases/ 8 | 9 | To use the Google Mock class generator, you need to call it 10 | on the command line passing the header file and class for which you want 11 | to generate a Google Mock class. 12 | 13 | Make sure to install the scripts somewhere in your path. Then you can 14 | run the program. 15 | 16 | gmock_gen.py header-file.h [ClassName]... 17 | 18 | If no ClassNames are specified, all classes in the file are emitted. 19 | 20 | To change the indentation from the default of 2, set INDENT in 21 | the environment. For example to use an indent of 4 spaces: 22 | 23 | INDENT=4 gmock_gen.py header-file.h ClassName 24 | 25 | This version was made from SVN revision 281 in the cppclean repository. 26 | 27 | Known Limitations 28 | ----------------- 29 | Not all code will be generated properly. For example, when mocking templated 30 | classes, the template information is lost. You will need to add the template 31 | information manually. 32 | 33 | Not all permutations of using multiple pointers/references will be rendered 34 | properly. These will also have to be fixed manually. 35 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/scripts/generator/cpp/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aau-cns/aaucns_rio/0771e1d70c0b2547321ee78150904dfa9b6580ee/external/yaml-cpp/test/gtest-1.10.0/googlemock/scripts/generator/cpp/__init__.py -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/scripts/generator/cpp/keywords.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # 3 | # Copyright 2007 Neal Norwitz 4 | # Portions Copyright 2007 Google Inc. 5 | # 6 | # Licensed under the Apache License, Version 2.0 (the "License"); 7 | # you may not use this file except in compliance with the License. 8 | # You may obtain a copy of the License at 9 | # 10 | # http://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | 18 | """C++ keywords and helper utilities for determining keywords.""" 19 | 20 | __author__ = 'nnorwitz@google.com (Neal Norwitz)' 21 | 22 | 23 | try: 24 | # Python 3.x 25 | import builtins 26 | except ImportError: 27 | # Python 2.x 28 | import __builtin__ as builtins 29 | 30 | 31 | if not hasattr(builtins, 'set'): 32 | # Nominal support for Python 2.3. 33 | from sets import Set as set 34 | 35 | 36 | TYPES = set('bool char int long short double float void wchar_t unsigned signed'.split()) 37 | TYPE_MODIFIERS = set('auto register const inline extern static virtual volatile mutable'.split()) 38 | ACCESS = set('public protected private friend'.split()) 39 | 40 | CASTS = set('static_cast const_cast dynamic_cast reinterpret_cast'.split()) 41 | 42 | OTHERS = set('true false asm class namespace using explicit this operator sizeof'.split()) 43 | OTHER_TYPES = set('new delete typedef struct union enum typeid typename template'.split()) 44 | 45 | CONTROL = set('case switch default if else return goto'.split()) 46 | EXCEPTION = set('try catch throw'.split()) 47 | LOOP = set('while do for break continue'.split()) 48 | 49 | ALL = TYPES | TYPE_MODIFIERS | ACCESS | CASTS | OTHERS | OTHER_TYPES | CONTROL | EXCEPTION | LOOP 50 | 51 | 52 | def IsKeyword(token): 53 | return token in ALL 54 | 55 | def IsBuiltinType(token): 56 | if token in ('virtual', 'inline'): 57 | # These only apply to methods, they can't be types by themselves. 58 | return False 59 | return token in TYPES or token in TYPE_MODIFIERS 60 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/scripts/generator/cpp/utils.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # 3 | # Copyright 2007 Neal Norwitz 4 | # Portions Copyright 2007 Google Inc. 5 | # 6 | # Licensed under the Apache License, Version 2.0 (the "License"); 7 | # you may not use this file except in compliance with the License. 8 | # You may obtain a copy of the License at 9 | # 10 | # http://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | 18 | """Generic utilities for C++ parsing.""" 19 | 20 | __author__ = 'nnorwitz@google.com (Neal Norwitz)' 21 | 22 | 23 | import sys 24 | 25 | 26 | # Set to True to see the start/end token indices. 27 | DEBUG = True 28 | 29 | 30 | def ReadFile(filename, print_error=True): 31 | """Returns the contents of a file.""" 32 | try: 33 | fp = open(filename) 34 | try: 35 | return fp.read() 36 | finally: 37 | fp.close() 38 | except IOError: 39 | if print_error: 40 | print('Error reading %s: %s' % (filename, sys.exc_info()[1])) 41 | return None 42 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/scripts/generator/gmock_gen.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | # 3 | # Copyright 2008 Google Inc. All Rights Reserved. 4 | # 5 | # Licensed under the Apache License, Version 2.0 (the "License"); 6 | # you may not use this file except in compliance with the License. 7 | # You may obtain a copy of the License at 8 | # 9 | # http://www.apache.org/licenses/LICENSE-2.0 10 | # 11 | # Unless required by applicable law or agreed to in writing, software 12 | # distributed under the License is distributed on an "AS IS" BASIS, 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 | # See the License for the specific language governing permissions and 15 | # limitations under the License. 16 | 17 | """Driver for starting up Google Mock class generator.""" 18 | 19 | __author__ = 'nnorwitz@google.com (Neal Norwitz)' 20 | 21 | import os 22 | import sys 23 | 24 | if __name__ == '__main__': 25 | # Add the directory of this script to the path so we can import gmock_class. 26 | sys.path.append(os.path.dirname(__file__)) 27 | 28 | from cpp import gmock_class 29 | # Fix the docstring in case they require the usage. 30 | gmock_class.__doc__ = gmock_class.__doc__.replace('gmock_class.py', __file__) 31 | gmock_class.main() 32 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/src/gmock-all.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | // 31 | // Google C++ Mocking Framework (Google Mock) 32 | // 33 | // This file #includes all Google Mock implementation .cc files. The 34 | // purpose is to allow a user to build Google Mock by compiling this 35 | // file alone. 36 | 37 | // This line ensures that gmock.h can be compiled on its own, even 38 | // when it's fused. 39 | #include "gmock/gmock.h" 40 | 41 | // The following lines pull in the real gmock *.cc files. 42 | #include "src/gmock-cardinalities.cc" 43 | #include "src/gmock-internal-utils.cc" 44 | #include "src/gmock-matchers.cc" 45 | #include "src/gmock-spec-builders.cc" 46 | #include "src/gmock.cc" 47 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/test/gmock-function-mocker_nc.cc: -------------------------------------------------------------------------------- 1 | #include "gmock/gmock.h" 2 | 3 | #include 4 | #include 5 | 6 | #if defined(TEST_MOCK_METHOD_INVALID_CONST_SPEC) 7 | 8 | struct Base { 9 | MOCK_METHOD(int, F, (), (onst)); 10 | }; 11 | 12 | #else 13 | 14 | // Sanity check - this should compile. 15 | 16 | #endif 17 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/test/gmock-function-mocker_nc_test.py: -------------------------------------------------------------------------------- 1 | """Negative compilation tests for Google Mock macro MOCK_METHOD.""" 2 | 3 | import os 4 | import sys 5 | 6 | IS_LINUX = os.name == "posix" and os.uname()[0] == "Linux" 7 | if not IS_LINUX: 8 | sys.stderr.write( 9 | "WARNING: Negative compilation tests are not supported on this platform") 10 | sys.exit(0) 11 | 12 | # Suppresses the 'Import not at the top of the file' lint complaint. 13 | # pylint: disable-msg=C6204 14 | from google3.testing.pybase import fake_target_util 15 | from google3.testing.pybase import googletest 16 | 17 | # pylint: enable-msg=C6204 18 | 19 | 20 | class GMockMethodNCTest(googletest.TestCase): 21 | """Negative compilation tests for MOCK_METHOD.""" 22 | 23 | # The class body is intentionally empty. The actual test*() methods 24 | # will be defined at run time by a call to 25 | # DefineNegativeCompilationTests() later. 26 | pass 27 | 28 | 29 | # Defines a list of test specs, where each element is a tuple 30 | # (test name, list of regexes for matching the compiler errors). 31 | TEST_SPECS = [ 32 | ("MOCK_METHOD_INVALID_CONST_SPEC", 33 | [r"onst cannot be recognized as a valid specification modifier"]), 34 | ] 35 | 36 | # Define a test method in GMockNCTest for each element in TEST_SPECS. 37 | fake_target_util.DefineNegativeCompilationTests( 38 | GMockMethodNCTest, 39 | "google3/third_party/googletest/googlemock/test/gmock-function-mocker_nc", 40 | "gmock-function-mocker_nc.o", TEST_SPECS) 41 | 42 | if __name__ == "__main__": 43 | googletest.main() 44 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/test/gmock-port_test.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | // Google Mock - a framework for writing C++ mock classes. 32 | // 33 | // This file tests the internal cross-platform support utilities. 34 | 35 | #include "gmock/internal/gmock-port.h" 36 | #include "gtest/gtest.h" 37 | 38 | // NOTE: if this file is left without tests for some reason, put a dummy 39 | // test here to make references to symbols in the gtest library and avoid 40 | // 'undefined symbol' linker errors in gmock_main: 41 | 42 | TEST(DummyTest, Dummy) {} 43 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/test/gmock_link2_test.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | // Google Mock - a framework for writing C++ mock classes. 32 | // 33 | // This file is for verifying that various Google Mock constructs do not 34 | // produce linker errors when instantiated in different translation units. 35 | // Please see gmock_link_test.h for details. 36 | 37 | #define LinkTest LinkTest2 38 | 39 | #include "test/gmock_link_test.h" 40 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googlemock/test/gmock_link_test.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | // Google Mock - a framework for writing C++ mock classes. 32 | // 33 | // This file is for verifying that various Google Mock constructs do not 34 | // produce linker errors when instantiated in different translation units. 35 | // Please see gmock_link_test.h for details. 36 | 37 | #define LinkTest LinkTest1 38 | 39 | #include "test/gmock_link_test.h" 40 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This file contains a list of people who've made non-trivial 2 | # contribution to the Google C++ Testing Framework project. People 3 | # who commit code to the project are encouraged to add their names 4 | # here. Please keep the list sorted by first names. 5 | 6 | Ajay Joshi 7 | Balázs Dán 8 | Bharat Mediratta 9 | Chandler Carruth 10 | Chris Prince 11 | Chris Taylor 12 | Dan Egnor 13 | Eric Roman 14 | Hady Zalek 15 | Jeffrey Yasskin 16 | Jói Sigurðsson 17 | Keir Mierle 18 | Keith Ray 19 | Kenton Varda 20 | Manuel Klimek 21 | Markus Heule 22 | Mika Raento 23 | Miklós Fazekas 24 | Pasi Valminen 25 | Patrick Hanna 26 | Patrick Riley 27 | Peter Kaminski 28 | Preston Jackson 29 | Rainer Klaffenboeck 30 | Russ Cox 31 | Russ Rufer 32 | Sean Mcafee 33 | Sigurður Ásgeirsson 34 | Tracy Bialik 35 | Vadim Berman 36 | Vlad Losev 37 | Zhanyong Wan 38 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2008, Google Inc. 2 | All rights reserved. 3 | 4 | Redistribution and use in source and binary forms, with or without 5 | modification, are permitted provided that the following conditions are 6 | met: 7 | 8 | * Redistributions of source code must retain the above copyright 9 | notice, this list of conditions and the following disclaimer. 10 | * Redistributions in binary form must reproduce the above 11 | copyright notice, this list of conditions and the following disclaimer 12 | in the documentation and/or other materials provided with the 13 | distribution. 14 | * Neither the name of Google Inc. nor the names of its 15 | contributors may be used to endorse or promote products derived from 16 | this software without specific prior written permission. 17 | 18 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/cmake/Config.cmake.in: -------------------------------------------------------------------------------- 1 | @PACKAGE_INIT@ 2 | include(CMakeFindDependencyMacro) 3 | if (@GTEST_HAS_PTHREAD@) 4 | set(THREADS_PREFER_PTHREAD_FLAG @THREADS_PREFER_PTHREAD_FLAG@) 5 | find_dependency(Threads) 6 | endif() 7 | 8 | include("${CMAKE_CURRENT_LIST_DIR}/@targets_export_name@.cmake") 9 | check_required_components("@project_name@") 10 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/cmake/gtest.pc.in: -------------------------------------------------------------------------------- 1 | prefix=${pcfiledir}/../.. 2 | libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@ 3 | includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@ 4 | 5 | Name: gtest 6 | Description: GoogleTest (without main() function) 7 | Version: @PROJECT_VERSION@ 8 | URL: https://github.com/google/googletest 9 | Libs: -L${libdir} -lgtest @CMAKE_THREAD_LIBS_INIT@ 10 | Cflags: -I${includedir} @GTEST_HAS_PTHREAD_MACRO@ @CMAKE_THREAD_LIBS_INIT@ 11 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/cmake/gtest_main.pc.in: -------------------------------------------------------------------------------- 1 | prefix=${pcfiledir}/../.. 2 | libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@ 3 | includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@ 4 | 5 | Name: gtest_main 6 | Description: GoogleTest (with main() function) 7 | Version: @PROJECT_VERSION@ 8 | URL: https://github.com/google/googletest 9 | Requires: gtest 10 | Libs: -L${libdir} -lgtest_main @CMAKE_THREAD_LIBS_INIT@ 11 | Cflags: -I${includedir} @GTEST_HAS_PTHREAD_MACRO@ @CMAKE_THREAD_LIBS_INIT@ 12 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/cmake/libgtest.la.in: -------------------------------------------------------------------------------- 1 | # libgtest.la - a libtool library file 2 | # Generated by libtool (GNU libtool) 2.4.6 3 | 4 | # Please DO NOT delete this file! 5 | # It is necessary for linking the library. 6 | 7 | # Names of this library. 8 | library_names='libgtest.so' 9 | 10 | # Is this an already installed library? 11 | installed=yes 12 | 13 | # Should we warn about portability when linking against -modules? 14 | shouldnotlink=no 15 | 16 | # Files to dlopen/dlpreopen 17 | dlopen='' 18 | dlpreopen='' 19 | 20 | # Directory that this library needs to be installed in: 21 | libdir='@CMAKE_INSTALL_FULL_LIBDIR@' 22 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/docs/samples.md: -------------------------------------------------------------------------------- 1 | # Googletest Samples {#samples} 2 | 3 | If you're like us, you'd like to look at 4 | [googletest samples.](https://github.com/google/googletest/tree/master/googletest/samples) 5 | The sample directory has a number of well-commented samples showing how to use a 6 | variety of googletest features. 7 | 8 | * Sample #1 shows the basic steps of using googletest to test C++ functions. 9 | * Sample #2 shows a more complex unit test for a class with multiple member 10 | functions. 11 | * Sample #3 uses a test fixture. 12 | * Sample #4 teaches you how to use googletest and `googletest.h` together to 13 | get the best of both libraries. 14 | * Sample #5 puts shared testing logic in a base test fixture, and reuses it in 15 | derived fixtures. 16 | * Sample #6 demonstrates type-parameterized tests. 17 | * Sample #7 teaches the basics of value-parameterized tests. 18 | * Sample #8 shows using `Combine()` in value-parameterized tests. 19 | * Sample #9 shows use of the listener API to modify Google Test's console 20 | output and the use of its reflection API to inspect test results. 21 | * Sample #10 shows use of the listener API to implement a primitive memory 22 | leak checker. 23 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/include/gtest/internal/custom/README.md: -------------------------------------------------------------------------------- 1 | # Customization Points 2 | 3 | The custom directory is an injection point for custom user configurations. 4 | 5 | ## Header `gtest.h` 6 | 7 | ### The following macros can be defined: 8 | 9 | * `GTEST_OS_STACK_TRACE_GETTER_` - The name of an implementation of 10 | `OsStackTraceGetterInterface`. 11 | * `GTEST_CUSTOM_TEMPDIR_FUNCTION_` - An override for `testing::TempDir()`. See 12 | `testing::TempDir` for semantics and signature. 13 | 14 | ## Header `gtest-port.h` 15 | 16 | The following macros can be defined: 17 | 18 | ### Flag related macros: 19 | 20 | * `GTEST_FLAG(flag_name)` 21 | * `GTEST_USE_OWN_FLAGFILE_FLAG_` - Define to 0 when the system provides its 22 | own flagfile flag parsing. 23 | * `GTEST_DECLARE_bool_(name)` 24 | * `GTEST_DECLARE_int32_(name)` 25 | * `GTEST_DECLARE_string_(name)` 26 | * `GTEST_DEFINE_bool_(name, default_val, doc)` 27 | * `GTEST_DEFINE_int32_(name, default_val, doc)` 28 | * `GTEST_DEFINE_string_(name, default_val, doc)` 29 | 30 | ### Logging: 31 | 32 | * `GTEST_LOG_(severity)` 33 | * `GTEST_CHECK_(condition)` 34 | * Functions `LogToStderr()` and `FlushInfoLog()` have to be provided too. 35 | 36 | ### Threading: 37 | 38 | * `GTEST_HAS_NOTIFICATION_` - Enabled if Notification is already provided. 39 | * `GTEST_HAS_MUTEX_AND_THREAD_LOCAL_` - Enabled if `Mutex` and `ThreadLocal` 40 | are already provided. Must also provide `GTEST_DECLARE_STATIC_MUTEX_(mutex)` 41 | and `GTEST_DEFINE_STATIC_MUTEX_(mutex)` 42 | * `GTEST_EXCLUSIVE_LOCK_REQUIRED_(locks)` 43 | * `GTEST_LOCK_EXCLUDED_(locks)` 44 | 45 | ### Underlying library support features 46 | 47 | * `GTEST_HAS_CXXABI_H_` 48 | 49 | ### Exporting API symbols: 50 | 51 | * `GTEST_API_` - Specifier for exported symbols. 52 | 53 | ## Header `gtest-printers.h` 54 | 55 | * See documentation at `gtest/gtest-printers.h` for details on how to define a 56 | custom printer. 57 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/include/gtest/internal/custom/gtest-port.h: -------------------------------------------------------------------------------- 1 | // Copyright 2015, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // Injection point for custom user configurations. See README for details 31 | // 32 | // ** Custom implementation starts here ** 33 | 34 | #ifndef GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PORT_H_ 35 | #define GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PORT_H_ 36 | 37 | #endif // GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PORT_H_ 38 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/include/gtest/internal/custom/gtest-printers.h: -------------------------------------------------------------------------------- 1 | // Copyright 2015, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // This file provides an injection point for custom printers in a local 31 | // installation of gTest. 32 | // It will be included from gtest-printers.h and the overrides in this file 33 | // will be visible to everyone. 34 | // 35 | // Injection point for custom user configurations. See README for details 36 | // 37 | // ** Custom implementation starts here ** 38 | 39 | #ifndef GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PRINTERS_H_ 40 | #define GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PRINTERS_H_ 41 | 42 | #endif // GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_PRINTERS_H_ 43 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/include/gtest/internal/custom/gtest.h: -------------------------------------------------------------------------------- 1 | // Copyright 2015, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // Injection point for custom user configurations. See README for details 31 | // 32 | // ** Custom implementation starts here ** 33 | 34 | #ifndef GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_H_ 35 | #define GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_H_ 36 | 37 | #endif // GTEST_INCLUDE_GTEST_INTERNAL_CUSTOM_GTEST_H_ 38 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/samples/sample1.h: -------------------------------------------------------------------------------- 1 | // Copyright 2005, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | // A sample program demonstrating using Google C++ testing framework. 31 | 32 | #ifndef GTEST_SAMPLES_SAMPLE1_H_ 33 | #define GTEST_SAMPLES_SAMPLE1_H_ 34 | 35 | // Returns n! (the factorial of n). For negative n, n! is defined to be 1. 36 | int Factorial(int n); 37 | 38 | // Returns true if and only if n is a prime number. 39 | bool IsPrime(int n); 40 | 41 | #endif // GTEST_SAMPLES_SAMPLE1_H_ 42 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/samples/sample4_unittest.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2005, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | #include "sample4.h" 32 | #include "gtest/gtest.h" 33 | 34 | namespace { 35 | // Tests the Increment() method. 36 | 37 | TEST(Counter, Increment) { 38 | Counter c; 39 | 40 | // Test that counter 0 returns 0 41 | EXPECT_EQ(0, c.Decrement()); 42 | 43 | // EXPECT_EQ() evaluates its arguments exactly once, so they 44 | // can have side effects. 45 | 46 | EXPECT_EQ(0, c.Increment()); 47 | EXPECT_EQ(1, c.Increment()); 48 | EXPECT_EQ(2, c.Increment()); 49 | 50 | EXPECT_EQ(3, c.Decrement()); 51 | } 52 | 53 | } // namespace 54 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/src/gtest_main.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2006, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | #include 31 | #include "gtest/gtest.h" 32 | 33 | #ifdef ARDUINO 34 | void setup() { 35 | testing::InitGoogleTest(); 36 | } 37 | 38 | void loop() { RUN_ALL_TESTS(); } 39 | 40 | #else 41 | 42 | GTEST_API_ int main(int argc, char **argv) { 43 | printf("Running main() from %s\n", __FILE__); 44 | testing::InitGoogleTest(&argc, argv); 45 | return RUN_ALL_TESTS(); 46 | } 47 | #endif 48 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/googletest-param-test-invalid-name1-test_.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2015, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | #include "gtest/gtest.h" 32 | 33 | namespace { 34 | class DummyTest : public ::testing::TestWithParam {}; 35 | 36 | TEST_P(DummyTest, Dummy) { 37 | } 38 | 39 | INSTANTIATE_TEST_SUITE_P(InvalidTestName, 40 | DummyTest, 41 | ::testing::Values("InvalidWithQuotes"), 42 | ::testing::PrintToStringParamName()); 43 | 44 | } // namespace 45 | 46 | int main(int argc, char *argv[]) { 47 | testing::InitGoogleTest(&argc, argv); 48 | return RUN_ALL_TESTS(); 49 | } 50 | 51 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/googletest-uninitialized-test_.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | #include "gtest/gtest.h" 32 | 33 | TEST(DummyTest, Dummy) { 34 | // This test doesn't verify anything. We just need it to create a 35 | // realistic stage for testing the behavior of Google Test when 36 | // RUN_ALL_TESTS() is called without 37 | // testing::InitGoogleTest() being called first. 38 | } 39 | 40 | int main() { 41 | return RUN_ALL_TESTS(); 42 | } 43 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/gtest-typed-test2_test.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008 Google Inc. 2 | // All Rights Reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | #include 32 | 33 | #include "test/gtest-typed-test_test.h" 34 | #include "gtest/gtest.h" 35 | 36 | #if GTEST_HAS_TYPED_TEST_P 37 | 38 | // Tests that the same type-parameterized test case can be 39 | // instantiated in different translation units linked together. 40 | // (ContainerTest is also instantiated in gtest-typed-test_test.cc.) 41 | INSTANTIATE_TYPED_TEST_SUITE_P(Vector, ContainerTest, 42 | testing::Types >); 43 | 44 | #endif // GTEST_HAS_TYPED_TEST_P 45 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/gtest_help_test_.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2009, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | // This program is meant to be run by gtest_help_test.py. Do not run 32 | // it directly. 33 | 34 | #include "gtest/gtest.h" 35 | 36 | // When a help flag is specified, this program should skip the tests 37 | // and exit with 0; otherwise the following test will be executed, 38 | // causing this program to exit with a non-zero code. 39 | TEST(HelpFlagTest, ShouldNotBeRun) { 40 | ASSERT_TRUE(false) << "Tests shouldn't be run when --help is specified."; 41 | } 42 | 43 | #if GTEST_HAS_DEATH_TEST 44 | TEST(DeathTest, UsedByPythonScriptToDetectSupportForDeathTestsInThisBinary) {} 45 | #endif 46 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/gtest_main_unittest.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2006, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | #include "gtest/gtest.h" 32 | 33 | // Tests that we don't have to define main() when we link to 34 | // gtest_main instead of gtest. 35 | 36 | namespace { 37 | 38 | TEST(GTestMainTest, ShouldSucceed) { 39 | } 40 | 41 | } // namespace 42 | 43 | // We are using the main() function defined in gtest_main.cc, so we 44 | // don't define it here. 45 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/gtest_skip_in_environment_setup_test.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2019, Google LLC. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google LLC. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // This test verifies that skipping in the environment results in the 31 | // testcases being skipped. 32 | 33 | #include 34 | #include "gtest/gtest.h" 35 | 36 | class SetupEnvironment : public testing::Environment { 37 | public: 38 | void SetUp() override { GTEST_SKIP() << "Skipping the entire environment"; } 39 | }; 40 | 41 | TEST(Test, AlwaysFails) { EXPECT_EQ(true, false); } 42 | 43 | int main(int argc, char **argv) { 44 | testing::InitGoogleTest(&argc, argv); 45 | 46 | testing::AddGlobalTestEnvironment(new SetupEnvironment()); 47 | 48 | return RUN_ALL_TESTS(); 49 | } 50 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/gtest_skip_test.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008 Google Inc. 2 | // All Rights Reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // Author: arseny.aprelev@gmail.com (Arseny Aprelev) 31 | // 32 | 33 | #include "gtest/gtest.h" 34 | 35 | using ::testing::Test; 36 | 37 | TEST(SkipTest, DoesSkip) { 38 | GTEST_SKIP(); 39 | EXPECT_EQ(0, 1); 40 | } 41 | 42 | class Fixture : public Test { 43 | protected: 44 | void SetUp() override { 45 | GTEST_SKIP() << "skipping all tests for this fixture"; 46 | } 47 | }; 48 | 49 | TEST_F(Fixture, SkipsOneTest) { 50 | EXPECT_EQ(5, 7); 51 | } 52 | 53 | TEST_F(Fixture, SkipsAnotherTest) { 54 | EXPECT_EQ(99, 100); 55 | } 56 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/gtest_testbridge_test_.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2018, Google LLC. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | 31 | // This program is meant to be run by gtest_test_filter_test.py. Do not run 32 | // it directly. 33 | 34 | #include "gtest/gtest.h" 35 | 36 | // These tests are used to detect if filtering is working. Only 37 | // 'TestThatSucceeds' should ever run. 38 | 39 | TEST(TestFilterTest, TestThatSucceeds) {} 40 | 41 | TEST(TestFilterTest, TestThatFails) { 42 | ASSERT_TRUE(false) << "This test should never be run."; 43 | } 44 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/gtest_xml_outfile1_test_.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // gtest_xml_outfile1_test_ writes some xml via TestProperty used by 31 | // gtest_xml_outfiles_test.py 32 | 33 | #include "gtest/gtest.h" 34 | 35 | class PropertyOne : public testing::Test { 36 | protected: 37 | void SetUp() override { RecordProperty("SetUpProp", 1); } 38 | void TearDown() override { RecordProperty("TearDownProp", 1); } 39 | }; 40 | 41 | TEST_F(PropertyOne, TestSomeProperties) { 42 | RecordProperty("TestSomeProperty", 1); 43 | } 44 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/gtest_xml_outfile2_test_.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2008, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | // 30 | // gtest_xml_outfile2_test_ writes some xml via TestProperty used by 31 | // gtest_xml_outfiles_test.py 32 | 33 | #include "gtest/gtest.h" 34 | 35 | class PropertyTwo : public testing::Test { 36 | protected: 37 | void SetUp() override { RecordProperty("SetUpProp", 2); } 38 | void TearDown() override { RecordProperty("TearDownProp", 2); } 39 | }; 40 | 41 | TEST_F(PropertyTwo, TestSomeProperties) { 42 | RecordProperty("TestSomeProperty", 2); 43 | } 44 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/googletest/test/production.cc: -------------------------------------------------------------------------------- 1 | // Copyright 2006, Google Inc. 2 | // All rights reserved. 3 | // 4 | // Redistribution and use in source and binary forms, with or without 5 | // modification, are permitted provided that the following conditions are 6 | // met: 7 | // 8 | // * Redistributions of source code must retain the above copyright 9 | // notice, this list of conditions and the following disclaimer. 10 | // * Redistributions in binary form must reproduce the above 11 | // copyright notice, this list of conditions and the following disclaimer 12 | // in the documentation and/or other materials provided with the 13 | // distribution. 14 | // * Neither the name of Google Inc. nor the names of its 15 | // contributors may be used to endorse or promote products derived from 16 | // this software without specific prior written permission. 17 | // 18 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 19 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 20 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 21 | // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 22 | // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 23 | // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 24 | // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 25 | // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 | // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 | // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 | // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 | 30 | // 31 | // This is part of the unit test for gtest_prod.h. 32 | 33 | #include "production.h" 34 | 35 | PrivateCode::PrivateCode() : x_(0) {} 36 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/library.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "googletest", 3 | "keywords": "unittest, unit, test, gtest, gmock", 4 | "description": "googletest is a testing framework developed by the Testing Technology team with Google's specific requirements and constraints in mind. No matter whether you work on Linux, Windows, or a Mac, if you write C++ code, googletest can help you. And it supports any kind of tests, not just unit tests.", 5 | "license": "BSD-3-Clause", 6 | "homepage": "https://github.com/google/googletest/blob/master/README.md", 7 | "repository": { 8 | "type": "git", 9 | "url": "https://github.com/google/googletest.git" 10 | }, 11 | "version": "1.8.1", 12 | "frameworks": "arduino", 13 | "platforms": [ 14 | "espressif32" 15 | ], 16 | "export": { 17 | "include": [ 18 | "googlemock/include/*", 19 | "googlemock/src/*", 20 | "googletest/include/*", 21 | "googletest/src/*" 22 | ], 23 | "exclude": [ 24 | "ci", 25 | "googlemock/build-aux", 26 | "googlemock/cmake", 27 | "googlemock/make", 28 | "googlemock/msvc", 29 | "googlemock/scripts", 30 | "googlemock/src/gmock-all.cc", 31 | "googlemock/src/gmock_main.cc", 32 | "googlemock/test", 33 | "googlemock/CMakeLists.txt", 34 | "googlemock/Makefile.am", 35 | "googlemock/configure.ac", 36 | "googletest/cmake", 37 | "googletest/codegear", 38 | "googletest/m4", 39 | "googletest/make", 40 | "googletest/msvc", 41 | "googletest/scripts", 42 | "googletest/src/gtest-all.cc", 43 | "googletest/src/gtest_main.cc", 44 | "googletest/test", 45 | "googletest/xcode", 46 | "googletest/CMakeLists.txt", 47 | "googletest/Makefile.am", 48 | "googletest/configure.ac" 49 | ] 50 | }, 51 | "build": { 52 | "flags": [ 53 | "-Igooglemock/include", 54 | "-Igooglemock", 55 | "-Igoogletest/include", 56 | "-Igoogletest" 57 | ] 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/gtest-1.10.0/platformio.ini: -------------------------------------------------------------------------------- 1 | ; PlatformIO Project Configuration File 2 | ; 3 | ; Build options: build flags, source filter 4 | ; Upload options: custom upload port, speed and extra flags 5 | ; Library options: dependencies, extra library storages 6 | ; Advanced options: extra scripting 7 | ; 8 | ; Please visit documentation for the other options and examples 9 | ; http://docs.platformio.org/page/projectconf.html 10 | 11 | 12 | [platformio] 13 | #src_dir = ./googlemock 14 | #src_dir = ./googletest 15 | src_dir = . 16 | 17 | [env:googletest_esp32] 18 | platform = espressif32 19 | board = esp32dev 20 | framework = arduino 21 | build_flags = -I./googletest/include -I./googletest 22 | src_filter = +<*> -<.git/> - - - - - - + + 23 | upload_speed = 921600 24 | 25 | [env:googlemock_esp32] 26 | platform = espressif32 27 | board = esp32dev 28 | framework = arduino 29 | build_flags = -I./googlemock/include -I./googletest/include -I./googletest -I./googlemock 30 | src_filter = +<*> -<.git/> - - - + + + 31 | upload_speed = 921600 32 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/handler_test.h: -------------------------------------------------------------------------------- 1 | #include "mock_event_handler.h" 2 | #include "yaml-cpp/yaml.h" // IWYU pragma: keep 3 | 4 | #include "gmock/gmock.h" 5 | #include "gtest/gtest.h" 6 | 7 | using ::testing::InSequence; 8 | using ::testing::NiceMock; 9 | using ::testing::StrictMock; 10 | 11 | namespace YAML { 12 | class HandlerTest : public ::testing::Test { 13 | protected: 14 | void Parse(const std::string& example) { 15 | std::stringstream stream(example); 16 | Parser parser(stream); 17 | while (parser.HandleNextDocument(handler)) { 18 | } 19 | } 20 | 21 | void IgnoreParse(const std::string& example) { 22 | std::stringstream stream(example); 23 | Parser parser(stream); 24 | while (parser.HandleNextDocument(nice_handler)) { 25 | } 26 | } 27 | 28 | InSequence sequence; 29 | StrictMock handler; 30 | NiceMock nice_handler; 31 | }; 32 | } 33 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/main.cpp: -------------------------------------------------------------------------------- 1 | #include "gtest/gtest.h" 2 | 3 | int main(int argc, char** argv) { 4 | ::testing::InitGoogleTest(&argc, argv); 5 | return RUN_ALL_TESTS(); 6 | } 7 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/mock_event_handler.h: -------------------------------------------------------------------------------- 1 | #include "yaml-cpp/emitterstyle.h" 2 | #include "yaml-cpp/eventhandler.h" 3 | #include "yaml-cpp/mark.h" 4 | 5 | #include "gmock/gmock.h" 6 | 7 | #include 8 | 9 | namespace YAML { 10 | 11 | class MockEventHandler : public EventHandler { 12 | public: 13 | MOCK_METHOD1(OnDocumentStart, void(const Mark&)); 14 | MOCK_METHOD0(OnDocumentEnd, void()); 15 | 16 | MOCK_METHOD2(OnNull, void(const Mark&, anchor_t)); 17 | MOCK_METHOD2(OnAlias, void(const Mark&, anchor_t)); 18 | MOCK_METHOD4(OnScalar, void(const Mark&, const std::string&, anchor_t, 19 | const std::string&)); 20 | 21 | MOCK_METHOD4(OnSequenceStart, void(const Mark&, const std::string&, anchor_t, 22 | EmitterStyle::value)); 23 | MOCK_METHOD0(OnSequenceEnd, void()); 24 | 25 | MOCK_METHOD4(OnMapStart, void(const Mark&, const std::string&, anchor_t, 26 | EmitterStyle::value)); 27 | MOCK_METHOD0(OnMapEnd, void()); 28 | MOCK_METHOD2(OnAnchor, void(const Mark&, const std::string&)); 29 | }; 30 | } // namespace YAML 31 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/ostream_wrapper_test.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | #include "gtest/gtest.h" 5 | #include "yaml-cpp/ostream_wrapper.h" 6 | 7 | namespace { 8 | TEST(OstreamWrapperTest, BufferNoWrite) { 9 | YAML::ostream_wrapper wrapper; 10 | EXPECT_STREQ("", wrapper.str()); 11 | } 12 | 13 | TEST(OstreamWrapperTest, BufferWriteStr) { 14 | YAML::ostream_wrapper wrapper; 15 | wrapper.write(std::string("Hello, world")); 16 | EXPECT_STREQ("Hello, world", wrapper.str()); 17 | } 18 | 19 | TEST(OstreamWrapperTest, BufferWriteCStr) { 20 | YAML::ostream_wrapper wrapper; 21 | wrapper.write("Hello, world"); 22 | EXPECT_STREQ("Hello, world", wrapper.str()); 23 | } 24 | 25 | TEST(OstreamWrapperTest, StreamNoWrite) { 26 | std::stringstream stream; 27 | YAML::ostream_wrapper wrapper(stream); 28 | EXPECT_STREQ(NULL, wrapper.str()); 29 | EXPECT_EQ("", stream.str()); 30 | } 31 | 32 | TEST(OstreamWrapperTest, StreamWriteStr) { 33 | std::stringstream stream; 34 | YAML::ostream_wrapper wrapper(stream); 35 | wrapper.write(std::string("Hello, world")); 36 | EXPECT_STREQ(NULL, wrapper.str()); 37 | EXPECT_EQ("Hello, world", stream.str()); 38 | } 39 | 40 | TEST(OstreamWrapperTest, StreamWriteCStr) { 41 | std::stringstream stream; 42 | YAML::ostream_wrapper wrapper(stream); 43 | wrapper.write("Hello, world"); 44 | EXPECT_STREQ(NULL, wrapper.str()); 45 | EXPECT_EQ("Hello, world", stream.str()); 46 | } 47 | 48 | TEST(OstreamWrapperTest, Position) { 49 | YAML::ostream_wrapper wrapper; 50 | wrapper.write("Hello, world\n"); 51 | EXPECT_EQ(1, wrapper.row()); 52 | EXPECT_EQ(0, wrapper.col()); 53 | EXPECT_EQ(13, wrapper.pos()); 54 | } 55 | 56 | TEST(OstreamWrapperTest, Comment) { 57 | YAML::ostream_wrapper wrapper; 58 | wrapper.write("Hello, world "); 59 | wrapper.set_comment(); 60 | EXPECT_TRUE(wrapper.comment()); 61 | wrapper.write("foo"); 62 | EXPECT_TRUE(wrapper.comment()); 63 | wrapper.write("\n"); 64 | EXPECT_FALSE(wrapper.comment()); 65 | } 66 | } 67 | -------------------------------------------------------------------------------- /external/yaml-cpp/test/parser_test.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include "yaml-cpp/parser.h" 3 | #include "yaml-cpp/exceptions.h" 4 | #include "mock_event_handler.h" 5 | #include "gtest/gtest.h" 6 | 7 | using YAML::Parser; 8 | using YAML::MockEventHandler; 9 | using ::testing::NiceMock; 10 | using ::testing::StrictMock; 11 | 12 | TEST(ParserTest, Empty) { 13 | Parser parser; 14 | 15 | EXPECT_FALSE(parser); 16 | 17 | StrictMock handler; 18 | EXPECT_FALSE(parser.HandleNextDocument(handler)); 19 | } 20 | 21 | TEST(ParserTest, CVE_2017_5950) { 22 | std::string excessive_recursion; 23 | for (auto i = 0; i != 16384; ++i) 24 | excessive_recursion.push_back('['); 25 | std::istringstream input{excessive_recursion}; 26 | Parser parser{input}; 27 | 28 | NiceMock handler; 29 | EXPECT_THROW(parser.HandleNextDocument(handler), YAML::DeepRecursion); 30 | } 31 | 32 | TEST(ParserTest, CVE_2018_20573) { 33 | std::string excessive_recursion; 34 | for (auto i = 0; i != 20535; ++i) 35 | excessive_recursion.push_back('{'); 36 | std::istringstream input{excessive_recursion}; 37 | Parser parser{input}; 38 | 39 | NiceMock handler; 40 | EXPECT_THROW(parser.HandleNextDocument(handler), YAML::DeepRecursion); 41 | } 42 | 43 | TEST(ParserTest, CVE_2018_20574) { 44 | std::string excessive_recursion; 45 | for (auto i = 0; i != 21989; ++i) 46 | excessive_recursion.push_back('{'); 47 | std::istringstream input{excessive_recursion}; 48 | Parser parser{input}; 49 | 50 | NiceMock handler; 51 | EXPECT_THROW(parser.HandleNextDocument(handler), YAML::DeepRecursion); 52 | } 53 | 54 | TEST(ParserTest, CVE_2019_6285) { 55 | std::string excessive_recursion; 56 | for (auto i = 0; i != 23100; ++i) 57 | excessive_recursion.push_back('['); 58 | excessive_recursion.push_back('f'); 59 | std::istringstream input{excessive_recursion}; 60 | Parser parser{input}; 61 | 62 | NiceMock handler; 63 | EXPECT_THROW(parser.HandleNextDocument(handler), YAML::DeepRecursion); 64 | } 65 | -------------------------------------------------------------------------------- /external/yaml-cpp/util/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_executable(yaml-cpp-sandbox sandbox.cpp) 2 | add_executable(yaml-cpp-parse parse.cpp) 3 | add_executable(yaml-cpp-read read.cpp) 4 | 5 | target_link_libraries(yaml-cpp-sandbox PRIVATE yaml-cpp) 6 | target_link_libraries(yaml-cpp-parse PRIVATE yaml-cpp) 7 | target_link_libraries(yaml-cpp-read PRIVATE yaml-cpp) 8 | 9 | set_property(TARGET yaml-cpp-sandbox PROPERTY OUTPUT_NAME sandbox) 10 | set_property(TARGET yaml-cpp-parse PROPERTY OUTPUT_NAME parse) 11 | set_property(TARGET yaml-cpp-read PROPERTY OUTPUT_NAME read) 12 | 13 | set_target_properties(yaml-cpp-sandbox 14 | PROPERTIES 15 | CXX_STANDARD_REQUIRED ON 16 | OUTPUT_NAME sandbox) 17 | 18 | set_target_properties(yaml-cpp-parse 19 | PROPERTIES 20 | CXX_STANDARD_REQUIRED ON 21 | OUTPUT_NAME parse) 22 | 23 | set_target_properties(yaml-cpp-read 24 | PROPERTIES 25 | CXX_STANDARD_REQUIRED ON 26 | OUTPUT_NAME read) 27 | 28 | if (NOT DEFINED CMAKE_CXX_STANDARD) 29 | set_target_properties(yaml-cpp-sandbox yaml-cpp-parse yaml-cpp-read 30 | PROPERTIES 31 | CXX_STANDARD 11) 32 | endif() 33 | -------------------------------------------------------------------------------- /external/yaml-cpp/util/parse.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | #include "yaml-cpp/eventhandler.h" 6 | #include "yaml-cpp/yaml.h" // IWYU pragma: keep 7 | 8 | class NullEventHandler : public YAML::EventHandler { 9 | public: 10 | void OnDocumentStart(const YAML::Mark&) override {} 11 | void OnDocumentEnd() override {} 12 | 13 | void OnNull(const YAML::Mark&, YAML::anchor_t) override {} 14 | void OnAlias(const YAML::Mark&, YAML::anchor_t) override {} 15 | void OnScalar(const YAML::Mark&, const std::string&, YAML::anchor_t, 16 | const std::string&) override {} 17 | 18 | void OnSequenceStart(const YAML::Mark&, const std::string&, YAML::anchor_t, 19 | YAML::EmitterStyle::value) override {} 20 | void OnSequenceEnd() override {} 21 | 22 | void OnMapStart(const YAML::Mark&, const std::string&, YAML::anchor_t, 23 | YAML::EmitterStyle::value) override {} 24 | void OnMapEnd() override {} 25 | }; 26 | 27 | void parse(std::istream& input) { 28 | try { 29 | YAML::Node doc = YAML::Load(input); 30 | std::cout << doc << "\n"; 31 | } catch (const YAML::Exception& e) { 32 | std::cerr << e.what() << "\n"; 33 | } 34 | } 35 | 36 | int main(int argc, char** argv) { 37 | if (argc > 1) { 38 | std::ifstream fin; 39 | fin.open(argv[1]); 40 | parse(fin); 41 | } else { 42 | parse(std::cin); 43 | } 44 | 45 | return 0; 46 | } 47 | -------------------------------------------------------------------------------- /external/yaml-cpp/util/sandbox.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #include "yaml-cpp/emitterstyle.h" 4 | #include "yaml-cpp/eventhandler.h" 5 | #include "yaml-cpp/yaml.h" // IWYU pragma: keep 6 | 7 | class NullEventHandler : public YAML::EventHandler { 8 | public: 9 | using Mark = YAML::Mark; 10 | using anchor_t = YAML::anchor_t; 11 | 12 | NullEventHandler() = default; 13 | 14 | void OnDocumentStart(const Mark&) override {} 15 | void OnDocumentEnd() override {} 16 | void OnNull(const Mark&, anchor_t) override {} 17 | void OnAlias(const Mark&, anchor_t) override {} 18 | void OnScalar(const Mark&, const std::string&, anchor_t, 19 | const std::string&) override {} 20 | void OnSequenceStart(const Mark&, const std::string&, anchor_t, 21 | YAML::EmitterStyle::value style) override {} 22 | void OnSequenceEnd() override {} 23 | void OnMapStart(const Mark&, const std::string&, anchor_t, 24 | YAML::EmitterStyle::value style) override {} 25 | void OnMapEnd() override {} 26 | }; 27 | 28 | int main() { 29 | YAML::Node root; 30 | 31 | for (;;) { 32 | YAML::Node node; 33 | root = node; 34 | } 35 | return 0; 36 | } 37 | -------------------------------------------------------------------------------- /external/yaml-cpp/yaml-cpp-config.cmake.in: -------------------------------------------------------------------------------- 1 | # - Config file for the yaml-cpp package 2 | # It defines the following variables 3 | # YAML_CPP_INCLUDE_DIR - include directory 4 | # YAML_CPP_LIBRARIES - libraries to link against 5 | 6 | # Compute paths 7 | get_filename_component(YAML_CPP_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH) 8 | set(YAML_CPP_INCLUDE_DIR "@CONFIG_INCLUDE_DIRS@") 9 | 10 | # Our library dependencies (contains definitions for IMPORTED targets) 11 | include("${YAML_CPP_CMAKE_DIR}/yaml-cpp-targets.cmake") 12 | 13 | # These are IMPORTED targets created by yaml-cpp-targets.cmake 14 | set(YAML_CPP_LIBRARIES "@EXPORT_TARGETS@") 15 | -------------------------------------------------------------------------------- /external/yaml-cpp/yaml-cpp.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@CMAKE_INSTALL_PREFIX@ 2 | exec_prefix=${prefix} 3 | includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@ 4 | libdir=@CMAKE_INSTALL_FULL_LIBDIR@ 5 | 6 | Name: Yaml-cpp 7 | Description: A YAML parser and emitter for C++ 8 | Version: @YAML_CPP_VERSION@ 9 | Requires: 10 | Libs: -L${libdir} -lyaml-cpp 11 | Cflags: -I${includedir} 12 | -------------------------------------------------------------------------------- /include/aaucns_rio/config.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _CONFIG_H_ 13 | #define _CONFIG_H_ 14 | 15 | namespace aaucns_rio 16 | { 17 | class Config 18 | { 19 | public: 20 | static constexpr bool kEnablePersistentFeatures = true; 21 | static constexpr bool kWriteFeaturesToFile = false; 22 | static constexpr bool kEnableLogging = false; 23 | static constexpr int kMaxPastElements = 10; 24 | static constexpr int kNSamplesForFeaturePersistence = 7; 25 | 26 | static_assert(kMaxPastElements > 0); 27 | static_assert(kEnablePersistentFeatures 28 | ? (kNSamplesForFeaturePersistence <= kMaxPastElements) 29 | : true); 30 | }; 31 | 32 | class ConfigFg : public Config 33 | { 34 | public: 35 | static constexpr int kNMaxIMUMeasurements = 512; 36 | static constexpr int kNPosesInWindow = 10; 37 | }; 38 | 39 | } // namespace aaucns_rio 40 | 41 | #endif /* CONFIG_H_ */ 42 | -------------------------------------------------------------------------------- /include/aaucns_rio/constants.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _CONSTANTS_H_ 13 | #define _CONSTANTS_H_ 14 | 15 | #include 16 | 17 | namespace aaucns_rio 18 | { 19 | class Constants 20 | { 21 | public: 22 | static const Eigen::Vector3d& getGravityVector(); 23 | }; 24 | 25 | } // namespace aaucns_rio 26 | 27 | #endif /* CONSTANTS_H_ */ 28 | -------------------------------------------------------------------------------- /include/aaucns_rio/fg/factors_data.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _FACTORS_DATA_H_ 13 | #define _FACTORS_DATA_H_ 14 | 15 | #include 16 | #include 17 | #include 18 | 19 | #include 20 | 21 | namespace aaucns_rio 22 | { 23 | class IMUFactorData 24 | { 25 | public: 26 | IMUFactorData(){}; 27 | IMUFactorData( 28 | const std::shared_ptr& 29 | imu_integrator) 30 | : imu_integrator_(imu_integrator) 31 | { 32 | } 33 | std::shared_ptr imu_integrator_; 34 | }; 35 | 36 | class RadialVelocityFactorData 37 | { 38 | public: 39 | // TODO(jan): Implement move constructor. 40 | RadialVelocityFactorData(){}; 41 | RadialVelocityFactorData(const Eigen::MatrixXd& velocities_and_points, 42 | const Eigen::Matrix& w_m) 43 | : velocities_and_points_(velocities_and_points), w_m_(w_m) 44 | { 45 | } 46 | 47 | Eigen::MatrixXd velocities_and_points_; 48 | // Angular velocity from IMU. 49 | Eigen::Matrix w_m_; 50 | }; 51 | 52 | class RadarDistanceFactorData 53 | { 54 | public: 55 | // TODO(jan): Implement move constructor. 56 | RadarDistanceFactorData(){}; 57 | RadarDistanceFactorData(const Features& features) : features_(features) {} 58 | 59 | Features features_; 60 | }; 61 | 62 | class RadarPFDistanceFactorData 63 | { 64 | public: 65 | // TODO(jan): Implement move constructor. 66 | RadarPFDistanceFactorData(){}; 67 | RadarPFDistanceFactorData(const State& most_recent_updated_state) 68 | : most_recent_updated_state_(most_recent_updated_state) 69 | { 70 | } 71 | 72 | State most_recent_updated_state_; 73 | }; 74 | 75 | } // namespace aaucns_rio 76 | 77 | #endif /* _FACTORS_DATA_H_ */ 78 | -------------------------------------------------------------------------------- /include/aaucns_rio/fg/imu_measurement.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _IMU_MEASUREMENT_H_ 13 | #define _IMU_MEASUREMENT_H_ 14 | 15 | #include 16 | 17 | #include 18 | 19 | namespace aaucns_rio 20 | { 21 | class IMUMeasurement 22 | { 23 | public: 24 | IMUMeasurement(const sensor_msgs::ImuConstPtr& msg); 25 | IMUMeasurement() = default; 26 | 27 | // Angular velocity from IMU. 28 | Eigen::Matrix w_m_; 29 | ///< acceleration from IMU. 30 | Eigen::Matrix a_m_; 31 | double timestamp_s_; 32 | }; 33 | 34 | } // namespace aaucns_rio 35 | 36 | #endif /* IMU_MEASUREMENT_H_ */ 37 | -------------------------------------------------------------------------------- /include/aaucns_rio/fg/rio_fg_replay.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _RIO_REPLAY_H_ 13 | #define _RIO_REPLAY_H_ 14 | 15 | #include 16 | #include 17 | 18 | #include 19 | #include 20 | #include 21 | 22 | #include "aaucns_rio/fg/rio_fg.h" 23 | 24 | namespace aaucns_rio 25 | { 26 | class RIOFgReplay : public RIOFg 27 | { 28 | public: 29 | // Open the bag and call run(). 30 | RIOFgReplay( 31 | const std::string& config_filename, 32 | const std::map& topic_names_and_topics, 33 | const std::string& input_bag, ros::NodeHandle& nh); 34 | ~RIOFgReplay(); 35 | 36 | // Run the loop where callbacks are called explicitely at each iteration of 37 | // the bag. 38 | void run(); 39 | 40 | protected: 41 | void writeState(const aaucns_rio::DoubleArrayStampedPtr& msg) override; 42 | void writePose( 43 | const geometry_msgs::PoseWithCovarianceStampedPtr& msg) override; 44 | 45 | private: 46 | ros::Publisher gt_pose_pub_; 47 | ros::Publisher imu_pub_; 48 | ros::Publisher pc2_pub_; 49 | std::map topic_names_and_topics_; 50 | rosbag::Bag input_bag_; 51 | rosbag::Bag output_bag_; 52 | }; 53 | 54 | } // namespace aaucns_rio 55 | 56 | #endif /* _RIO_REPLAY_H_ */ 57 | -------------------------------------------------------------------------------- /include/aaucns_rio/iteration.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _ITERATION_H_ 13 | #define _ITERATION_H_ 14 | 15 | #include 16 | 17 | #include 18 | #include 19 | #include 20 | 21 | namespace aaucns_rio 22 | { 23 | // *Not* to be used in multithread environment. Log from one callback at a time. 24 | class Iteration 25 | { 26 | public: 27 | Iteration(debug::Logger& logger) : logger_(logger) 28 | { 29 | logger_.startLoggingIteration(); 30 | } 31 | 32 | ~Iteration() { logger_.stopLoggingIteration(); } 33 | 34 | // TODO(jan): implement similar function for std::vector. 35 | template 36 | void writeEntry(const Eigen::MatrixBase& matrix, 37 | const std::string& entry_name) 38 | { 39 | logger_.writeEigenMatrixToFile(matrix, entry_name); 40 | } 41 | 42 | private: 43 | // Keep `Logger` object around as long as `Iteration` is alive. 44 | debug::Logger& logger_; 45 | }; 46 | } // namespace aaucns_rio 47 | 48 | #endif /* _ITERATION_H_ */ 49 | -------------------------------------------------------------------------------- /include/aaucns_rio/parameters.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _PARAMETERS_H_ 13 | #define _PARAMETERS_H_ 14 | 15 | namespace aaucns_rio 16 | { 17 | class Parameters 18 | { 19 | public: 20 | EIGEN_MAKE_ALIGNED_OPERATOR_NEW 21 | Parameters() = default; 22 | 23 | double noise_acc_ = 0.083; 24 | double noise_accbias_ = 0.0083; 25 | double noise_gyr_ = 0.013; 26 | double noise_gyrbias_ = 0.0013; 27 | double noise_qri_ = 0.0; 28 | double noise_pri_ = 0.0; 29 | double noise_meas1_ = 0.05; 30 | double noise_meas2_ = 0.01; 31 | double noise_meas3_ = 0.01; 32 | double noise_meas4_ = 0.01; 33 | double noise_pf_x_ = 0.0; 34 | double noise_pf_y_ = 0.0; 35 | double noise_pf_z_ = 0.0; 36 | // Parameters not directly used in the implementation. 37 | double noise_qwv_ = 0.0; 38 | double noise_aux_ = 0.0; 39 | double noise_scale_ = 0.0; 40 | }; 41 | 42 | } // namespace aaucns_rio 43 | 44 | #endif /* _PARAMETERS_H_ */ 45 | -------------------------------------------------------------------------------- /include/aaucns_rio/pcl_conversions_rio.h: -------------------------------------------------------------------------------- 1 | #ifndef _PCL_CONVERSIONS_RIO_H_ 2 | #define _PCL_CONVERSIONS_RIO_H_ 3 | 4 | #include 5 | #include 6 | #include 7 | #include 8 | #include 9 | #include 10 | 11 | namespace aaucns_rio 12 | { 13 | struct RadarPointCloudType 14 | { 15 | PCL_ADD_POINT4D; // position in [m] 16 | float intensity; // CFAR cell to side noise ratio in [dB] 17 | float doppler; // Doppler velocity in [m/s] 18 | EIGEN_MAKE_ALIGNED_OPERATOR_NEW 19 | }; 20 | 21 | struct RadarPointCloudNTNUType 22 | { 23 | PCL_ADD_POINT4D; // position in [m] 24 | float intensity; // CFAR cell to side noise ratio in [dB] 25 | float velocity; // Doppler velocity in [m/s] 26 | EIGEN_MAKE_ALIGNED_OPERATOR_NEW 27 | }; 28 | 29 | bool rosPCLMsgToRadarPCL(const sensor_msgs::PointCloud2& ros_msg_pcl, 30 | pcl::PointCloud& radar_pcl); 31 | 32 | void xyziToRadarPCL(const pcl::PointCloud& pcl_xyzi, 33 | pcl::PointCloud& radar_pcl); 34 | 35 | void NTNUToRadarPCL( 36 | const pcl::PointCloud& ntnu_point_cloud, 37 | pcl::PointCloud& radar_pcl); 38 | 39 | } // namespace aaucns_rio 40 | 41 | #endif /* _PCL_CONVERSIONS_RIO_H_ */ 42 | -------------------------------------------------------------------------------- /include/aaucns_rio/rio_replay.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _RIO_REPLAY_H_ 13 | #define _RIO_REPLAY_H_ 14 | 15 | #include 16 | #include 17 | 18 | #include 19 | #include 20 | #include 21 | 22 | #include "aaucns_rio/rio.h" 23 | 24 | namespace aaucns_rio 25 | { 26 | class RIOReplay : public RIO 27 | { 28 | public: 29 | // Open the bag and call run(). 30 | RIOReplay(const std::string& config_filename, 31 | const std::map& topic_names_and_topics, 32 | const std::string& input_bag, ros::NodeHandle& nh); 33 | ~RIOReplay(); 34 | 35 | // Run the loop where callbacks are called explicitely at each iteration of 36 | // the bag. 37 | void run(); 38 | 39 | protected: 40 | void writeState(const aaucns_rio::DoubleArrayStampedPtr& msg) override; 41 | void writePose( 42 | const geometry_msgs::PoseWithCovarianceStampedPtr& msg) override; 43 | 44 | private: 45 | ros::Publisher gt_pose_pub_; 46 | ros::Publisher imu_pub_; 47 | ros::Publisher pc2_pub_; 48 | std::map topic_names_and_topics_; 49 | rosbag::Bag input_bag_; 50 | rosbag::Bag output_bag_; 51 | }; 52 | 53 | } // namespace aaucns_rio 54 | 55 | #endif /* _RIO_REPLAY_H_ */ 56 | -------------------------------------------------------------------------------- /include/aaucns_rio/state_predictor.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _STATE_PREDICTOR_H_ 13 | #define _STATE_PREDICTOR_H_ 14 | 15 | #include 16 | 17 | #include "aaucns_rio/parameters.h" 18 | #include "aaucns_rio/state.h" 19 | 20 | namespace aaucns_rio 21 | { 22 | class StatePredictor 23 | { 24 | public: 25 | EIGEN_MAKE_ALIGNED_OPERATOR_NEW 26 | StatePredictor(); 27 | const Eigen::Vector3d& getGravityVector() const; 28 | void predictState(const double dt, const State& previous_state, 29 | State& current_state); 30 | void predictProcessCovariance(const double dt, const State& previous_state, 31 | const Parameters& parameters, 32 | State& current_state); 33 | 34 | // Get omega matrix (JPL notation). 35 | Eigen::Matrix getOmegaJPL( 36 | const Eigen::Vector3d& angular_vel) const; 37 | 38 | private: 39 | Eigen::Vector3d g_; 40 | // discrete state propagation matrix 41 | Eigen::MatrixXd Fd_; 42 | // discrete propagation noise matrix 43 | Eigen::MatrixXd Qd_; 44 | }; 45 | 46 | } // namespace aaucns_rio 47 | 48 | #endif /* _STATE_PREDICTOR_H_ */ 49 | -------------------------------------------------------------------------------- /include/aaucns_rio/timer.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _TIMER_H_ 13 | #define _TIMER_H_ 14 | 15 | #include 16 | #include 17 | #include 18 | 19 | namespace aaucns_rio 20 | { 21 | template 22 | t computeMovingAverage(const t& sample) 23 | { 24 | static long int sample_number = 0; 25 | ++sample_number; 26 | static t sum = 0; 27 | sum = sum + sample; 28 | return (sum / sample_number); 29 | } 30 | 31 | class Timer 32 | { 33 | public: 34 | Timer() : busy_(false) {} 35 | void start() 36 | { 37 | busy_ = true; 38 | start_ = std::chrono::high_resolution_clock::now(); 39 | } 40 | double stop() 41 | { 42 | if (busy_) 43 | { 44 | reset(); 45 | std::chrono::duration ms_timediff = 46 | std::chrono::high_resolution_clock::now() - start_; 47 | return ms_timediff.count(); 48 | } 49 | else 50 | { 51 | throw std::runtime_error("Start the timer first."); 52 | } 53 | } 54 | void reset() { busy_ = false; } 55 | 56 | private: 57 | bool busy_; 58 | std::chrono::high_resolution_clock::time_point start_; 59 | }; 60 | 61 | } // namespace aaucns_rio 62 | 63 | #endif /* TIMER_H_ */ 64 | -------------------------------------------------------------------------------- /include/aaucns_rio/velocity_provider.h: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #ifndef _VELOCITY_PROVIDER_H_ 13 | #define _VELOCITY_PROVIDER_H_ 14 | 15 | #include 16 | #include 17 | 18 | #include 19 | 20 | #include "aaucns_rio/debug.h" 21 | #include "aaucns_rio/pcl_conversions_rio.h" 22 | 23 | namespace aaucns_rio 24 | { 25 | class VelocityProvider 26 | { 27 | public: 28 | static constexpr int kNPointAndVelocityDimension = 4; 29 | static constexpr int kNRansacIter = 17; 30 | static constexpr int kNRansacPoints = 3; 31 | static constexpr float kInlierThreshold = 0.15; 32 | 33 | VelocityProvider() = default; 34 | static Eigen::MatrixXd getPointsAndVelocities( 35 | const pcl::PointCloud& current_pc2, 36 | debug::Logger& logger); 37 | 38 | private: 39 | static void runRansac(Eigen::MatrixXd& velocities_and_points); 40 | static bool solveLLS(Eigen::MatrixXd& potential_inliers, 41 | Eigen::Vector3d& estimated_radar_vel); 42 | }; 43 | 44 | } // namespace aaucns_rio 45 | 46 | #endif /* _VELOCITY_PROVIDER_H_ */ 47 | -------------------------------------------------------------------------------- /launch/aaucns_rio.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /launch/aaucns_rio_fg.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /launch/aaucns_rio_fg_replay.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /launch/aaucns_rio_fg_replay_gdb.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /launch/aaucns_rio_gdb.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /launch/aaucns_rio_memcheck.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /launch/aaucns_rio_replay.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /launch/aaucns_rio_replay_gdb.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /msg/DoubleArrayStamped.msg: -------------------------------------------------------------------------------- 1 | Header header 2 | float64[] data -------------------------------------------------------------------------------- /nodes/rio_fg_node.cpp: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #include 13 | 14 | #include "aaucns_rio/fg/rio_fg.h" 15 | 16 | int main(int argc, char** argv) 17 | { 18 | ros::init(argc, argv, "rio_fg_node"); 19 | ros::NodeHandle nh("~"); 20 | aaucns_rio::RIOFg rio_fg("/ti_mmwave/radar_scan_pcl", 21 | "/mavros/imu/data_raw", "/pose", 22 | "/aaucns_rio_state", "config_fg.yaml", 23 | aaucns_rio::Config::kWriteFeaturesToFile, nh); 24 | 25 | while (ros::ok()) 26 | { 27 | ros::spin(); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /nodes/rio_fg_replay_node.cpp: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #include 13 | 14 | #include 15 | #include 16 | 17 | #include "aaucns_rio/config.h" 18 | #include "aaucns_rio/fg/rio_fg.h" 19 | #include "aaucns_rio/fg/rio_fg_replay.h" 20 | 21 | /* 22 | This node opens a bagfile and loops through all messages and and manually calls 23 | callback functions in order to avoid the network traffic causing processing 24 | delays. 25 | */ 26 | 27 | int main(int argc, char **argv) 28 | { 29 | ros::init(argc, argv, "rio_fg_replay_node"); 30 | ros::NodeHandle nh("~"); 31 | 32 | const std::map topics_and_topic_names{ 33 | // Output. 34 | {"state", "/aaucns_rio_state"}, 35 | {"pose", "/pose"}, 36 | // Input. 37 | {"imu", "/mavros/imu/data_raw"}, 38 | {"gt_pose", "/twins_cns4/vrpn_client/raw_pose"}, 39 | {"pc2", "/ti_mmwave/radar_scan_pcl"}}; 40 | // Make sure the bagfile is inside ~/.ros folder wherefrom the binary is 41 | // executed. 42 | const std::string input_bagfile = "awr_7.bag"; 43 | aaucns_rio::RIOFgReplay rio_fg_replay("config.yaml", topics_and_topic_names, 44 | input_bagfile, nh); 45 | rio_fg_replay.run(); 46 | } 47 | -------------------------------------------------------------------------------- /nodes/rio_node.cpp: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #include 13 | 14 | #include "aaucns_rio/config.h" 15 | #include "aaucns_rio/rio.h" 16 | 17 | int main(int argc, char** argv) 18 | { 19 | ros::init(argc, argv, "rio_node"); 20 | ros::NodeHandle nh("~"); 21 | 22 | aaucns_rio::RIO rio("/ti_mmwave/radar_scan_pcl", "/mavros/imu/data_raw", 23 | "/pose", "/aaucns_rio_state", "config.yaml", 24 | aaucns_rio::Config::kWriteFeaturesToFile, nh); 25 | 26 | while (ros::ok()) 27 | { 28 | ros::spin(); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /nodes/rio_replay_node.cpp: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #include 13 | 14 | #include 15 | #include 16 | 17 | #include "aaucns_rio/config.h" 18 | #include "aaucns_rio/rio.h" 19 | #include "aaucns_rio/rio_replay.h" 20 | 21 | /* 22 | This node opens a bagfile and loops through all messages and and manually calls 23 | callback functions in order to avoid the network traffic causing processing 24 | delays. 25 | */ 26 | 27 | int main(int argc, char **argv) 28 | { 29 | ros::init(argc, argv, "rio_replay_node"); 30 | ros::NodeHandle nh("~"); 31 | 32 | const std::map topics_and_topic_names{ 33 | // Output. 34 | {"state", "/aaucns_rio_state"}, 35 | {"pose", "/pose"}, 36 | // Input. 37 | {"imu", "/mavros/imu/data_raw"}, 38 | {"gt_pose", "/twins_cns4/vrpn_client/raw_pose"}, 39 | {"pc2", "/ti_mmwave/radar_scan_pcl"}}; 40 | // Make sure the bagfile is inside ~/.ros folder wherefrom the binary is 41 | // executed. 42 | const std::string input_bagfile = "awr_6.bag"; 43 | aaucns_rio::RIOReplay rio_replay("config.yaml", topics_and_topic_names, 44 | input_bagfile, nh); 45 | rio_replay.run(); 46 | } 47 | -------------------------------------------------------------------------------- /src/constants.cpp: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #include "aaucns_rio/constants.h" 13 | 14 | namespace aaucns_rio 15 | { 16 | const Eigen::Vector3d& Constants::getGravityVector() 17 | { 18 | static Eigen::Vector3d g = (Eigen::Vector3d() << 0, 0, 9.81).finished(); 19 | return g; 20 | } 21 | 22 | } // namespace aaucns_rio -------------------------------------------------------------------------------- /src/fg/imu_measurement.cpp: -------------------------------------------------------------------------------- 1 | // Copyright (C) 2024 Jan Michalczyk, Control of Networked Systems, University 2 | // of Klagenfurt, Austria. 3 | // 4 | // All rights reserved. 5 | // 6 | // This software is licensed under the terms of the BSD-2-Clause-License with 7 | // no commercial use allowed, the full terms of which are made available 8 | // in the LICENSE file. No license in patents is granted. 9 | // 10 | // You can contact the author at 11 | 12 | #include "aaucns_rio/fg/imu_measurement.h" 13 | 14 | namespace aaucns_rio 15 | { 16 | IMUMeasurement::IMUMeasurement(const sensor_msgs::ImuConstPtr& msg) 17 | { 18 | a_m_ << msg->linear_acceleration.x, msg->linear_acceleration.y, 19 | msg->linear_acceleration.z; 20 | w_m_ << msg->angular_velocity.x, msg->angular_velocity.y, 21 | msg->angular_velocity.z; 22 | timestamp_s_ = msg->header.stamp.toSec(); 23 | } 24 | 25 | } // namespace aaucns_rio --------------------------------------------------------------------------------