20 #ifndef _agentx_session_h_
21 #define _agentx_session_h_
23 #include <agent_pp/agent++.h>
24 #include <agent_pp/snmp_pp_ext.h>
30 #ifdef AGENTPP_NAMESPACE
34 #if !defined (AGENTXPP_DECL_TEMPL_LIST_VBX)
35 #define AGENTXPP_DECL_TEMPL_LIST_VBX
54 u_int
get_id()
const {
return sessionID; }
55 void set_id(u_int i) { sessionID = i; }
58 void set_byte_order(
bool newOrder)
59 { networkByteOrder = newOrder; }
63 NS_SNMP OctetStr
get_descr()
const {
return descr; }
68 static u_int get_next_session_id();
70 void add_agent_caps(
const NS_SNMP OctetStr& c,
const Oidx& oid)
71 { sysORIDs.add(
new Vbx(oid, c));}
72 void remove_agent_caps(
const NS_SNMP OctetStr&,
const Oidx&
id);
75 return new ListCursor<Vbx>(&sysORIDs); }
81 bool is_unable_to_respond()
82 {
return (consecutiveTimeouts >=
111 #if !defined (AGENTXPP_DECL_TEMPL_LIST_AGENTXSESSION)
112 #define AGENTXPP_DECL_TEMPL_LIST_AGENTXSESSION
177 virtual u_int make_new_session(
bool, u_char,
179 const NS_SNMP OctetStr&,
188 ListCursor<AgentXSession> get_sessions()
189 {
return ListCursor<AgentXSession>(&sessions); }
194 void clear() { sessions.clearAll(); }
241 #ifdef AGENTPP_NAMESPACE