summaryrefslogtreecommitdiff
path: root/TAO/tao/Transport.inl
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/tao/Transport.inl')
-rw-r--r--TAO/tao/Transport.inl69
1 files changed, 69 insertions, 0 deletions
diff --git a/TAO/tao/Transport.inl b/TAO/tao/Transport.inl
index ef9faafb1ac..384f16eb45d 100644
--- a/TAO/tao/Transport.inl
+++ b/TAO/tao/Transport.inl
@@ -189,4 +189,73 @@ TAO_Transport::sent_byte_count (void) const
return this->sent_byte_count_;
}
+ACE_INLINE TAO::Transport::Stats*
+TAO_Transport::stats (void) const
+{
+ return this->stats_;
+}
+
+ACE_INLINE
+TAO::Transport::Stats::Stats ()
+ : messages_rcvd_ (0)
+ , messages_sent_ (0)
+ , bytes_rcvd_()
+ , bytes_sent_ ()
+ , opened_since_ ()
+{
+}
+
+ACE_INLINE void
+TAO::Transport::Stats::messages_sent (size_t message_length)
+{
+ this->messages_sent_++;
+ this->bytes_sent_.sample (message_length);
+ ACE_DEBUG ((LM_DEBUG, "TAO - message_length: %d\n", message_length));
+}
+
+ACE_INLINE CORBA::LongLong
+TAO::Transport::Stats::messages_sent (void) const
+{
+ return this->messages_sent_;
+}
+
+ACE_INLINE CORBA::LongLong
+TAO::Transport::Stats::bytes_sent (void) const
+{
+ return this->bytes_sent_.sum_;
+}
+
+ACE_INLINE void
+TAO::Transport::Stats::messages_received (size_t message_length)
+{
+ this->messages_rcvd_++;
+ this->bytes_rcvd_.sample (message_length);
+ ACE_DEBUG ((LM_DEBUG, "TAO - messages_received: %d\n", message_length));
+}
+
+ACE_INLINE CORBA::LongLong
+TAO::Transport::Stats::messages_received (void) const
+{
+ return this->messages_rcvd_;
+}
+
+ACE_INLINE CORBA::LongLong
+TAO::Transport::Stats::bytes_received (void) const
+{
+ return this->bytes_rcvd_.sum_;
+}
+
+ACE_INLINE void
+TAO::Transport::Stats::opened_since (const ACE_Time_Value& tv)
+{
+ this->opened_since_ = tv;
+}
+
+ACE_INLINE const ACE_Time_Value&
+TAO::Transport::Stats::opened_since (void) const
+{
+ return this->opened_since_;
+}
+
+
TAO_END_VERSIONED_NAMESPACE_DECL