Exercises: Sensor Repository (std::map)

Exercises

Write a class SensorRepository that is there to act as a “registry” for sensors. Sensors are registered there using a decriptive name.

Dependencies

cluster_cxx03 C++ cluster_cxx03_stl Standard Template Library cluster_cxx03_stl_associative_containers Associative Containers cluster_cxx03_data_encapsulation Data Encapsulation cluster_cxx03_templates C++ Template Basics cluster_cxx03_exceptions Exceptions cluster_cxx C++: Miscellaneous Live-Hacking cluster_cxx_exercises C++ Exercises cluster_cxx_exercises_stl C++ Exercises: Standard Template Library cluster_cxx_exercises_stl_sensor_repository Exercises: Sensor Repository (std::map) cluster_c The C Programming Language cluster_c_introduction Introduction cxx03_introduction Introduction c_introduction_installation Installation cxx03_introduction->c_introduction_installation cxx03_stl_basics Standard Template Library: Basics cxx03_templates_class_templates Class Templates cxx03_stl_basics->cxx03_templates_class_templates cxx03_stl_associative_containers_basics Associative Containers cxx03_stl_associative_containers_basics->cxx03_stl_basics cxx03_stl_associative_containers_map std::map cxx03_stl_associative_containers_map->cxx03_stl_associative_containers_basics cxx03_data_encapsulation_classes_objects Classes and Objects cxx03_data_encapsulation_classes_objects->cxx03_introduction cxx03_data_encapsulation_c Object Oriented Programming In Good Ol’ C cxx03_data_encapsulation_classes_objects->cxx03_data_encapsulation_c cxx03_data_encapsulation_c->cxx03_introduction cxx03_templates_function_templates Function Templates cxx03_exceptions_try_catch try - catch cxx03_templates_function_templates->cxx03_exceptions_try_catch cxx03_templates_class_templates->cxx03_templates_function_templates cxx03_exceptions_basics Basics cxx03_exceptions_try_catch->cxx03_data_encapsulation_classes_objects cxx03_exceptions_try_catch->cxx03_exceptions_basics cxx_exercises_stl_map Exercise: std::map<> cxx_exercises_stl_map->cxx03_stl_associative_containers_map cxx_exercises_stl_sensor_repository_lookup_sunny Lookup - Sunny Case cxx_exercises_stl_sensor_repository_insert_sunny Insert - Sunny Case cxx_exercises_stl_sensor_repository_lookup_sunny->cxx_exercises_stl_sensor_repository_insert_sunny cxx_exercises_stl_sensor_repository_memory_leaks Memory Leaks? cxx_exercises_stl_sensor_repository_memory_leaks->cxx_exercises_stl_sensor_repository_lookup_sunny cxx_exercises_stl_sensor_repository_memory_leaks->cxx_exercises_stl_sensor_repository_insert_sunny cxx_exercises_stl_sensor_repository_remove_not_found Remove - Not Found cxx_exercises_stl_sensor_repository_memory_leaks->cxx_exercises_stl_sensor_repository_remove_not_found cxx_exercises_stl_sensor_repository_insert_no_overwrite Insert - Not Overwriting Existing Elements cxx_exercises_stl_sensor_repository_memory_leaks->cxx_exercises_stl_sensor_repository_insert_no_overwrite cxx_exercises_stl_sensor_repository_size_const .size() Is const cxx_exercises_stl_sensor_repository_memory_leaks->cxx_exercises_stl_sensor_repository_size_const cxx_exercises_stl_sensor_repository_lookup_not_found Lookup - Not Found cxx_exercises_stl_sensor_repository_memory_leaks->cxx_exercises_stl_sensor_repository_lookup_not_found cxx_exercises_stl_sensor_repository_remove_sunny Remove - Sunny Case cxx_exercises_stl_sensor_repository_memory_leaks->cxx_exercises_stl_sensor_repository_remove_sunny cxx_exercises_stl_sensor_repository_insert_sunny->cxx_exercises_stl_map cxx_exercises_stl_sensor_repository_remove_not_found->cxx_exercises_stl_sensor_repository_remove_sunny cxx_exercises_stl_sensor_repository_insert_no_overwrite->cxx_exercises_stl_sensor_repository_insert_sunny cxx_exercises_stl_sensor_repository_size_const->cxx_exercises_stl_sensor_repository_insert_sunny cxx_exercises_stl_sensor_repository_lookup_not_found->cxx_exercises_stl_sensor_repository_lookup_sunny cxx_exercises_stl_sensor_repository_remove_sunny->cxx_exercises_stl_sensor_repository_insert_sunny