Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 25, 2006, 10:39:29 AM (18 years ago)
Author:
bensch
Message:

consts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/proxy/src/lib/network/monitor/network_node.cc

    r9406 r9451  
    152152 * @return the client in the list or NULL if none
    153153 */
    154 PeerInfo* NetworkNode::getClient(int index)
     154PeerInfo* NetworkNode::getClient(int index) const
    155155{
    156156  if( this->clientList.size() < index)
    157157    return NULL;
    158158
    159   std::list<PeerInfo*>::iterator it = this->clientList.begin();
     159  std::list<PeerInfo*>::const_iterator it = this->clientList.begin();
    160160  for(int i = 0; it != this->clientList.end(); it++, i++)
    161161  {
     
    172172 * @return the active proxy server in the list or NULL if none
    173173 */
    174 PeerInfo* NetworkNode::getActiveProxyServer(int index)
     174PeerInfo* NetworkNode::getActiveProxyServer(int index) const
    175175{
    176176  if( this->activeProxyServerList.size() < index)
    177177    return NULL;
    178178
    179   std::list<PeerInfo*>::iterator it = this->activeProxyServerList.begin();
     179  std::list<PeerInfo*>::const_iterator it = this->activeProxyServerList.begin();
    180180  for(int i = 0; it != this->activeProxyServerList.end(); it++, i++)
    181181  {
     
    192192 * @return the passive proxy server in the list or NULL if none
    193193 */
    194 PeerInfo* NetworkNode::getPassiveProxyServer(int index)
     194PeerInfo* NetworkNode::getPassiveProxyServer(int index) const
    195195{
    196196  if( this->passiveProxyServerList.size() < index)
    197197    return NULL;
    198198
    199   std::list<PeerInfo*>::iterator it = this->passiveProxyServerList.begin();
     199  std::list<PeerInfo*>::const_iterator it = this->passiveProxyServerList.begin();
    200200  for(int i = 0; it != this->passiveProxyServerList.end(); it++, i++)
    201201  {
     
    212212 * @return the master server in the list or NULL if none
    213213 */
    214 PeerInfo* NetworkNode::getMasterServer(int index)
     214PeerInfo* NetworkNode::getMasterServer(int index) const
    215215{
    216216  if( this->masterServerList.size() < index)
    217217    return NULL;
    218218
    219   std::list<PeerInfo*>::iterator it = this->masterServerList.begin();
     219  std::list<PeerInfo*>::const_iterator it = this->masterServerList.begin();
    220220  for(int i = 0; it != this->masterServerList.end(); it++, i++)
    221221  {
     
    232232 * @param depth: depth in the tree
    233233 */
    234 void NetworkNode::debug(int depth)
     234void NetworkNode::debug(int depth) const
    235235{
    236236  PRINT(0)(" = %s\n", this->peerInfo->getNodeTypeString().c_str());
    237237
    238238  PRINT(0)("    master servers: %i\n", this->masterServerList.size());
    239   std::list<PeerInfo*>::iterator it = this->masterServerList.begin();
     239  std::list<PeerInfo*>::const_iterator it = this->masterServerList.begin();
    240240  for(; it != this->masterServerList.end(); it++)
    241241  {
Note: See TracChangeset for help on using the changeset viewer.