Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

pandatool/src/pstatserver/pStatMonitor.I

Go to the documentation of this file.
00001 // Filename: pStatMonitor.I
00002 // Created by:  drose (14Jul00)
00003 //
00004 ////////////////////////////////////////////////////////////////////
00005 //
00006 // PANDA 3D SOFTWARE
00007 // Copyright (c) 2001, Disney Enterprises, Inc.  All rights reserved
00008 //
00009 // All use of this software is subject to the terms of the Panda 3d
00010 // Software license.  You should have received a copy of this license
00011 // along with this source code; you will also find a current copy of
00012 // the license at http://www.panda3d.org/license.txt .
00013 //
00014 // To contact the maintainers of this program write to
00015 // panda3d@yahoogroups.com .
00016 //
00017 ////////////////////////////////////////////////////////////////////
00018 
00019 
00020 ////////////////////////////////////////////////////////////////////
00021 //     Function: PStatMonitor::get_client_data
00022 //       Access: Public
00023 //  Description: Returns the client data associated with this monitor.
00024 ////////////////////////////////////////////////////////////////////
00025 INLINE const PStatClientData *PStatMonitor::
00026 get_client_data() const {
00027   return _client_data;
00028 }
00029 
00030 ////////////////////////////////////////////////////////////////////
00031 //     Function: PStatMonitor::get_collector_name
00032 //       Access: Public
00033 //  Description: Returns the name of the indicated collector, if it is
00034 //               known.
00035 ////////////////////////////////////////////////////////////////////
00036 INLINE string PStatMonitor::
00037 get_collector_name(int collector_index) {
00038   if (!_client_data.is_null() &&
00039       _client_data->has_collector(collector_index)) {
00040     return _client_data->get_collector_name(collector_index);
00041   }
00042   return "Unknown";
00043 }
00044 
00045 ////////////////////////////////////////////////////////////////////
00046 //     Function: PStatMonitor::is_client_known
00047 //       Access: Public
00048 //  Description: Returns true if we've yet received the "hello"
00049 //               message from the client indicating its name, etc.
00050 ////////////////////////////////////////////////////////////////////
00051 INLINE bool PStatMonitor::
00052 is_client_known() const {
00053   return _client_known;
00054 }
00055 
00056 ////////////////////////////////////////////////////////////////////
00057 //     Function: PStatMonitor::get_client_hostname
00058 //       Access: Public
00059 //  Description: Returns the hostname of the client we're connected
00060 //               to, if known.  This may not be known immediately at
00061 //               creation time, but should be learned shortly
00062 //               thereafter when we receive the client's "hello"
00063 //               message.  See is_client_known().
00064 ////////////////////////////////////////////////////////////////////
00065 INLINE string PStatMonitor::
00066 get_client_hostname() const {
00067   return _client_hostname;
00068 }
00069 
00070 ////////////////////////////////////////////////////////////////////
00071 //     Function: PStatMonitor::get_client_progname
00072 //       Access: Public
00073 //  Description: Returns the program name of the client we're
00074 //               connected to, if known.  This may not be known
00075 //               immediately at creation time, but should be learned
00076 //               shortly thereafter when we receive the client's
00077 //               "hello" message.  See is_client_known().
00078 ////////////////////////////////////////////////////////////////////
00079 INLINE string PStatMonitor::
00080 get_client_progname() const {
00081   return _client_progname;
00082 }

Generated on Fri May 2 03:21:36 2003 for Panda-Tool by doxygen1.3