GreenCloud Simulator
Public Member Functions | Private Attributes | List of all members
NIC Class Reference

#include <nic.h>

Inheritance diagram for NIC:
Inheritance graph
[legend]
Collaboration diagram for NIC:
Collaboration graph
[legend]

Public Member Functions

 NIC ()
 
virtual ~NIC ()
 
void setRp (ResourceProvider *rp)
 
virtual double getUtilization ()
 
- Public Member Functions inherited from DcResource
 DcResource ()
 
virtual ~DcResource ()
 
virtual int command (int argc, const char *const *argv)
 
virtual int setSpecification (ResourceSpec *resspec)
 
virtual double getPower ()
 
virtual double getMaxPower ()
 
virtual void print ()
 
- Public Member Functions inherited from Resource
 Resource (res_type t, double a, std::vector< Capacity > cap)
 
void print ()
 
virtual ~Resource ()
 
res_type getType ()
 
double getArch ()
 

Private Attributes

ResourceProviderrp_
 

Additional Inherited Members

- Static Public Member Functions inherited from Resource
static res_type translateType (const char *t)
 
- Public Attributes inherited from DcResource
ResourceSpecspecification
 
- Public Attributes inherited from Resource
std::vector< Capacitycapacity
 
- Protected Member Functions inherited from Resource
 Resource ()
 
Resourceoperator= (const Resource &r)
 
int setType (const char *t)
 
int setCapacity (std::vector< Capacity > cap)
 
void sortCapacity ()
 
- Protected Attributes inherited from Resource
res_type type
 
double arch
 

Detailed Description

Definition at line 14 of file nic.h.

Constructor & Destructor Documentation

NIC::NIC ( )

Definition at line 19 of file nic.cc.

19  {
20 
21 
22 }
NIC::~NIC ( )
virtual

Definition at line 24 of file nic.cc.

24  {
25 
26 }

Member Function Documentation

double NIC::getUtilization ( )
virtual

Reimplemented from DcResource.

Definition at line 32 of file nic.cc.

32  {
33  return rp_->getResTypeUtil(Networking);
34 }
double getResTypeUtil(res_type type)
ResourceProvider * rp_
Definition: nic.h:21
void NIC::setRp ( ResourceProvider rp)

Definition at line 28 of file nic.cc.

28  {
29  rp_ = rp;
30 }
ResourceProvider * rp_
Definition: nic.h:21

Member Data Documentation

ResourceProvider* NIC::rp_
private

Definition at line 21 of file nic.h.


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