GreenCloud Simulator
Public Member Functions | Protected Attributes | List of all members
PoaBufList Class Reference

#include <provideroutagent.h>

Collaboration diagram for PoaBufList:
Collaboration graph
[legend]

Public Member Functions

 PoaBufList ()
 
 ~PoaBufList ()
 
void insert (PoaBuf *poabuf)
 
PoaBufdetach ()
 

Protected Attributes

PoaBufhead_
 
PoaBuftail_
 

Detailed Description

Definition at line 35 of file provideroutagent.h.

Constructor & Destructor Documentation

PoaBufList::PoaBufList ( )
inline

Definition at line 38 of file provideroutagent.h.

38 : head_(NULL), tail_(NULL) {}
PoaBuf * tail_
PoaBuf * head_
PoaBufList::~PoaBufList ( )

Definition at line 70 of file provideroutagent.cc.

71 {
72  while (head_ != NULL) {
73  tail_ = head_;
74  head_ = head_->next_;
75  delete tail_;
76  }
77 }
PoaBuf * tail_
PoaBuf * head_
PoaBuf * next_

Member Function Documentation

PoaBuf * PoaBufList::detach ( )

Definition at line 89 of file provideroutagent.cc.

90 {
91  if (head_ == NULL)
92  return NULL;
93  PoaBuf *p = head_;
94  if ((head_ = head_->next_) == NULL)
95  tail_ = NULL;
96  return p;
97 }
PoaBuf * tail_
PoaBuf * head_
PoaBuf * next_
void PoaBufList::insert ( PoaBuf poabuf)

Definition at line 79 of file provideroutagent.cc.

80 {
81  if (tail_ == NULL)
82  head_ = tail_ = poabuf;
83  else {
84  tail_->next_ = poabuf;
85  tail_ = poabuf;
86  }
87 }
PoaBuf * tail_
PoaBuf * head_
PoaBuf * next_

Member Data Documentation

PoaBuf* PoaBufList::head_
protected

Definition at line 45 of file provideroutagent.h.

PoaBuf* PoaBufList::tail_
protected

Definition at line 46 of file provideroutagent.h.


The documentation for this class was generated from the following files: