diff options
author | Andrey Oleynik <aoleynik@luxoft.com> | 2017-01-04 11:33:00 +0200 |
---|---|---|
committer | Andrey Oleynik <aoleynik@luxoft.com> | 2017-01-04 11:52:33 +0200 |
commit | c786400ef832f5e268f241c8810fe9f375809718 (patch) | |
tree | af8427711c855602858a9c786a67a78bdafe66fc /src/components/application_manager/include/application_manager | |
parent | f20f0856747aac5c144430d8560667b4521f5be6 (diff) | |
download | sdl_core-c786400ef832f5e268f241c8810fe9f375809718.tar.gz |
Fixes style, logging, enum declaration
Relates-to: APPLINK-25591
Diffstat (limited to 'src/components/application_manager/include/application_manager')
-rw-r--r-- | src/components/application_manager/include/application_manager/request_controller.h | 2 | ||||
-rw-r--r-- | src/components/application_manager/include/application_manager/request_tracker.h | 73 |
2 files changed, 38 insertions, 37 deletions
diff --git a/src/components/application_manager/include/application_manager/request_controller.h b/src/components/application_manager/include/application_manager/request_controller.h index c4869e1a90..d3a5a0b821 100644 --- a/src/components/application_manager/include/application_manager/request_controller.h +++ b/src/components/application_manager/include/application_manager/request_controller.h @@ -233,7 +233,7 @@ class RequestController { * @brief Checks whether all constraints are met before adding of request into * processing queue. Verifies amount of pending requests, amount of requests * per time scale for different HMI levels - * @param request - request to check contraints for + * @param request - request to check constraints for * @param level - HMI level in which request has been issued * @return Appropriate result code of verification */ diff --git a/src/components/application_manager/include/application_manager/request_tracker.h b/src/components/application_manager/include/application_manager/request_tracker.h index c53057b773..36ab3eaefb 100644 --- a/src/components/application_manager/include/application_manager/request_tracker.h +++ b/src/components/application_manager/include/application_manager/request_tracker.h @@ -1,35 +1,34 @@ /* - * Copyright (c) 2017, Ford Motor Company - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * Redistributions of source code must retain the above copyright notice, this - * list of conditions and the following disclaimer. - * - * Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following - * disclaimer in the documentation and/or other materials provided with the - * distribution. - * - * Neither the name of the Ford Motor Company nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" - * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE - * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF - * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN - * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) -* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -* POSSIBILITY OF SUCH DAMAGE. -*/ - + * Copyright (c) 2017, Ford Motor Company + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * Redistributions of source code must retain the above copyright notice, this + * list of conditions and the following disclaimer. + * + * Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following + * disclaimer in the documentation and/or other materials provided with the + * distribution. + * + * Neither the name of the Ford Motor Company nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE + * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ #ifndef SRC_COMPONENTS_APPLICATION_MANAGER_INCLUDE_APPLICATION_MANAGER_REQUEST_TRACKER_H_ #define SRC_COMPONENTS_APPLICATION_MANAGER_INCLUDE_APPLICATION_MANAGER_REQUEST_TRACKER_H_ @@ -47,7 +46,7 @@ namespace request_controller { /** * @brief The TrackResult enum defines results of application request tracking */ -enum TrackResult { +enum class TrackResult { kSuccess, kNoneLevelMaxRequestsExceeded, kMaxRequestsExceeded @@ -55,9 +54,11 @@ enum TrackResult { /** * @brief The RequestTracker class tracks requests per time constraints. - * There are several parameters in configuration file defining maximum requests + * There are several parameters in configuration file defining maximum + * requests * number and time scale for that number, so application must consider that, - * otherwise it will be disconnected and won't be registered till next ignition + * otherwise it will be disconnected and won't be registered till next + * ignition * cycle. */ class RequestTracker { @@ -88,7 +89,8 @@ class RequestTracker { typedef std::map<ApplicationID, RequestAddedAt> ApplicationsRequestsTracker; /** - * @brief Checks whether maximum requests number is exceeded per defined time + * @brief Checks whether maximum requests number is exceeded per defined + * time * scale. * @param app_id Unique application id * @param time_scale Time scale defined in configuration file @@ -119,6 +121,5 @@ class RequestTracker { }; } // namespace request_controller - } // namespace application_manager #endif // SRC_COMPONENTS_APPLICATION_MANAGER_INCLUDE_APPLICATION_MANAGER_REQUEST_TRACKER_H_ |