summaryrefslogtreecommitdiff
path: root/src/components/connection_handler/include/connection_handler/connection_handler.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/connection_handler/include/connection_handler/connection_handler.h')
-rw-r--r--src/components/connection_handler/include/connection_handler/connection_handler.h20
1 files changed, 18 insertions, 2 deletions
diff --git a/src/components/connection_handler/include/connection_handler/connection_handler.h b/src/components/connection_handler/include/connection_handler/connection_handler.h
index 08bef9715..9cd80a408 100644
--- a/src/components/connection_handler/include/connection_handler/connection_handler.h
+++ b/src/components/connection_handler/include/connection_handler/connection_handler.h
@@ -45,6 +45,12 @@
* \brief SmartDeviceLink connection_handler namespace.
*/
namespace connection_handler {
+
+ enum CloseSessionReason {
+ kCommon = 0,
+ kFlood
+ };
+
/**
* \class ConnectionHandler
* \brief SmartDeviceLink ConnectionHandler interface class
@@ -100,13 +106,23 @@ class ConnectionHandler {
/**
* Close session associated with the key
*/
- virtual void CloseSession(uint32_t key) = 0;
+ virtual void CloseSession(uint32_t key, CloseSessionReason close_reason) = 0;
/**
* Close session
*/
virtual void CloseSession(ConnectionHandle connection_handle,
- uint8_t session_id) = 0;
+ uint8_t session_id,
+ CloseSessionReason close_reason) = 0;
+
+ /**
+ * @brief SendEndService allows to end up specific service.
+ *
+ * @param key application identifier whose service should be closed.
+ *
+ * @param service_type the service that should be closed.
+ */
+ virtual void SendEndService(uint32_t key, uint8_t service_type) = 0;
/**
* \brief Start heartbeat for specified session