From dbfb070f52b53d1b3461e581b72a05b71c509e22 Mon Sep 17 00:00:00 2001 From: Perry Werneck Date: Mon, 30 Sep 2019 09:54:16 -0300 Subject: [PATCH] Adding get/set methods for session timeout attribute. --- client/src/include/lib3270/ipc.h | 8 ++++++++ 1 file changed, 8 insertions(+), 0 deletions(-) diff --git a/client/src/include/lib3270/ipc.h b/client/src/include/lib3270/ipc.h index 12b40ce..f6bb85e 100644 --- a/client/src/include/lib3270/ipc.h +++ b/client/src/include/lib3270/ipc.h @@ -734,6 +734,10 @@ Attribute getAttribute(const char *name) const; std::vector getAttributes() const; + inline time_t getTimeout() const noexcept { + return this->timeout; + } + inline Attribute operator[](const char *name) const { return getAttribute(name); } @@ -778,6 +782,10 @@ } // Set properties + inline void setTimeout(time_t timeout = DEFAULT_TIMEOUT) noexcept { + this->timeout = timeout; + } + inline void setUnlockDelay(unsigned short delay = 350) { session->setUnlockDelay(delay); } -- libgit2 0.21.2