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

ACE_Flow_Spec Class Reference

Wrapper class that defines the flow spec QoS information, which is used by IntServ (RSVP) and DiffServ. More...

#include <OS_QoS.h>

List of all members.

Public Methods

 ACE_Flow_Spec (void)
 Default constructor. More...

 ACE_Flow_Spec (u_long token_rate, u_long token_bucket_size, u_long peak_bandwidth, u_long latency, u_long delay_variation, ACE_SERVICE_TYPE service_type, u_long max_sdu_size, u_long minimum_policed_size, int ttl, int priority)
 Constructor that initializes all the fields. More...

u_long token_rate (void) const
 Get the token rate in bytes/sec. More...

void token_rate (u_long tr)
 Set the token rate in bytes/sec. More...

u_long token_bucket_size (void) const
 Get the token bucket size in bytes. More...

void token_bucket_size (u_long tbs)
 Set the token bucket size in bytes. More...

u_long peak_bandwidth (void) const
 Get the PeakBandwidth in bytes/sec. More...

void peak_bandwidth (u_long pb)
 Set the PeakBandwidth in bytes/sec. More...

u_long latency (void) const
 Get the latency in microseconds. More...

void latency (u_long l)
 Set the latency in microseconds. More...

u_long delay_variation (void) const
 Get the delay variation in microseconds. More...

void delay_variation (u_long dv)
 Set the delay variation in microseconds. More...

ACE_SERVICE_TYPE service_type (void) const
 Get the service type. More...

void service_type (ACE_SERVICE_TYPE st)
 Set the service type. More...

u_long max_sdu_size (void) const
 Get the maximum SDU size in bytes. More...

void max_sdu_size (u_long mss)
 Set the maximum SDU size in bytes. More...

u_long minimum_policed_size (void) const
 Get the minimum policed size in bytes. More...

void minimum_policed_size (u_long mps)
 Set the minimum policed size in bytes. More...

int ttl (void) const
 Get the time-to-live. More...

void ttl (int t)
 Set the time-to-live. More...

int priority (void) const
 Get the priority. More...

void priority (int p)
 Set the priority. More...


Private Attributes

u_long token_rate_
u_long token_bucket_size_
u_long peak_bandwidth_
u_long latency_
u_long delay_variation_
ACE_SERVICE_TYPE service_type_
u_long max_sdu_size_
u_long minimum_policed_size_
int ttl_
int priority_


Detailed Description

Wrapper class that defines the flow spec QoS information, which is used by IntServ (RSVP) and DiffServ.

Definition at line 101 of file OS_QoS.h.


Constructor & Destructor Documentation

ACE_Flow_Spec::ACE_Flow_Spec void   
 

Default constructor.

Definition at line 60 of file OS_QoS.cpp.

References delay_variation_, latency_, max_sdu_size_, minimum_policed_size_, peak_bandwidth_, priority_, service_type_, token_bucket_size_, token_rate_, and ttl_.

00061 {
00062 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00063     defined (ACE_HAS_WINSOCK2_GQOS)
00064   this->TokenRate = 0;
00065   this->TokenBucketSize = 0;
00066   this->PeakBandwidth = 0;
00067   this->Latency = 0;
00068   this->DelayVariation = 0;
00069 #if defined(ACE_HAS_WINSOCK2_GQOS)
00070   this->ServiceType = 0;
00071   this->MaxSduSize = 0;
00072   this->MinimumPolicedSize = 0;
00073 #endif /* ACE_HAS_WINSOCK2_GQOS */
00074 #else
00075 
00076   this->token_rate_ = 0;
00077   this->token_bucket_size_ = 0;
00078   this->peak_bandwidth_ = 0;
00079   this->latency_ = 0;
00080   this->delay_variation_ = 0;
00081   this->service_type_ = 0;
00082   this->max_sdu_size_ = 0;
00083   this->minimum_policed_size_ = 0;
00084   this->ttl_ = 0;
00085   this->priority_ = 0;
00086 
00087 #endif /* defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) */
00088 }

ACE_Flow_Spec::ACE_Flow_Spec u_long    token_rate,
u_long    token_bucket_size,
u_long    peak_bandwidth,
u_long    latency,
u_long    delay_variation,
ACE_SERVICE_TYPE    service_type,
u_long    max_sdu_size,
u_long    minimum_policed_size,
int    ttl,
int    priority
 

Constructor that initializes all the fields.

Definition at line 16 of file OS_QoS.cpp.

References ACE_SERVICE_TYPE, delay_variation, delay_variation_, latency, latency_, max_sdu_size, max_sdu_size_, minimum_policed_size, minimum_policed_size_, peak_bandwidth, peak_bandwidth_, priority, priority_, service_type, service_type_, token_bucket_size, token_bucket_size_, token_rate, token_rate_, ttl, and ttl_.

00026 {
00027 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00028   this->TokenRate = token_rate;
00029   this->TokenBucketSize = token_bucket_size;
00030   this->PeakBandwidth = peak_bandwidth;
00031   this->Latency = latency;
00032   this->DelayVariation = delay_variation;
00033 #if defined(ACE_HAS_WINSOCK2_GQOS)
00034   this->ServiceType = service_type;
00035   this->MaxSduSize = max_sdu_size;
00036   this->MinimumPolicedSize = minimum_policed_size;
00037 #else
00038   ACE_UNUSED_ARG (service_type);
00039   ACE_UNUSED_ARG (max_sdu_size);
00040   ACE_UNUSED_ARG (minimum_policed_size);
00041 #endif /* ACE_HAS_WINSOCK2_GQOS */
00042   ACE_UNUSED_ARG (ttl);
00043   ACE_UNUSED_ARG (priority);
00044 #else
00045 
00046   this->token_rate_ = token_rate;
00047   this->token_bucket_size_ = token_bucket_size;
00048   this->peak_bandwidth_ = peak_bandwidth;
00049   this->latency_ = latency;
00050   this->delay_variation_ = delay_variation;
00051   this->service_type_ = service_type;
00052   this->max_sdu_size_ = max_sdu_size;
00053   this->minimum_policed_size_ = minimum_policed_size;
00054   this->ttl_ = ttl;
00055   this->priority_ = priority;
00056 
00057 #endif /* defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) */
00058 }


Member Function Documentation

void ACE_Flow_Spec::delay_variation u_long    dv
 

Set the delay variation in microseconds.

Definition at line 180 of file OS_QoS.cpp.

References delay_variation_.

00181 {
00182 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00183   this->DelayVariation = dv;
00184 #else
00185   this->delay_variation_ = dv;
00186 #endif /* ACE_HAS_WINSOCK2 */
00187 }

u_long ACE_Flow_Spec::delay_variation void    const
 

Get the delay variation in microseconds.

Definition at line 171 of file OS_QoS.cpp.

References delay_variation_.

Referenced by ACE_Flow_Spec.

00172 {
00173 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00174   return this->DelayVariation;
00175 #else
00176   return this->delay_variation_;
00177 #endif /* ACE_HAS_WINSOCK2 */
00178 }

void ACE_Flow_Spec::latency u_long    l
 

Set the latency in microseconds.

Definition at line 161 of file OS_QoS.cpp.

References latency_.

00162 {
00163 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00164   this->Latency = l;
00165 #else
00166   this->latency_ = l;
00167 #endif /* ACE_HAS_WINSOCK2 */
00168 }

u_long ACE_Flow_Spec::latency void    const
 

Get the latency in microseconds.

Definition at line 151 of file OS_QoS.cpp.

References latency_.

Referenced by ACE_Flow_Spec.

00152 {
00153 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00154   return this->Latency;
00155 #else
00156   return this->latency_;
00157 #endif /* ACE_HAS_WINSOCK2 */
00158 }

void ACE_Flow_Spec::max_sdu_size u_long    mss
 

Set the maximum SDU size in bytes.

Definition at line 223 of file OS_QoS.cpp.

References max_sdu_size_.

00224 {
00225 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00226     defined (ACE_HAS_WINSOCK2_GQOS)
00227   this->MaxSduSize = mss;
00228 #else
00229   this->max_sdu_size_ = mss;
00230 #endif /* ACE_HAS_WINSOCK2 */
00231 }

u_long ACE_Flow_Spec::max_sdu_size void    const
 

Get the maximum SDU size in bytes.

Definition at line 212 of file OS_QoS.cpp.

References max_sdu_size_.

Referenced by ACE_Flow_Spec.

00213 {
00214 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00215     defined (ACE_HAS_WINSOCK2_GQOS)
00216   return this->MaxSduSize;
00217 #else
00218   return this->max_sdu_size_;
00219 #endif /* ACE_HAS_WINSOCK2 */
00220 }

void ACE_Flow_Spec::minimum_policed_size u_long    mps
 

Set the minimum policed size in bytes.

Definition at line 245 of file OS_QoS.cpp.

References minimum_policed_size_.

00246 {
00247 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00248     defined (ACE_HAS_WINSOCK2_GQOS)
00249   this->MinimumPolicedSize = mps;
00250 #else
00251   this->minimum_policed_size_ = mps;
00252 #endif /* ACE_HAS_WINSOCK2 */
00253 }

u_long ACE_Flow_Spec::minimum_policed_size void    const
 

Get the minimum policed size in bytes.

Definition at line 234 of file OS_QoS.cpp.

References minimum_policed_size_.

Referenced by ACE_Flow_Spec.

00235 {
00236 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00237     defined (ACE_HAS_WINSOCK2_GQOS)
00238   return this->MinimumPolicedSize;
00239 #else
00240   return this->minimum_policed_size_;
00241 #endif /* ACE_HAS_WINSOCK2 */
00242 }

void ACE_Flow_Spec::peak_bandwidth u_long    pb
 

Set the PeakBandwidth in bytes/sec.

Definition at line 141 of file OS_QoS.cpp.

References peak_bandwidth_.

00142 {
00143 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00144   this->PeakBandwidth = pb;
00145 #else
00146   this->peak_bandwidth_ = pb;
00147 #endif /* ACE_HAS_WINSOCK2 */
00148 }

u_long ACE_Flow_Spec::peak_bandwidth void    const
 

Get the PeakBandwidth in bytes/sec.

Definition at line 131 of file OS_QoS.cpp.

References peak_bandwidth_.

Referenced by ACE_Flow_Spec.

00132 {
00133 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00134   return this->PeakBandwidth;
00135 #else
00136   return this->peak_bandwidth_;
00137 #endif /* ACE_HAS_WINSOCK2 */
00138 }

void ACE_Flow_Spec::priority int    p
 

Set the priority.

Definition at line 290 of file OS_QoS.cpp.

References priority_.

00291 {
00292 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00293     defined (ACE_HAS_WINSOCK2_GQOS)
00294   ACE_UNUSED_ARG (p);
00295   // TBD...
00296 #else
00297   this->priority_ = p;
00298 #endif /* ACE_HAS_WINSOCK2 */
00299 }

int ACE_Flow_Spec::priority void    const
 

Get the priority.

Definition at line 279 of file OS_QoS.cpp.

References priority_.

Referenced by ACE_Flow_Spec.

00280 {
00281 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00282     defined (ACE_HAS_WINSOCK2_GQOS)
00283   ACE_NOTSUP_RETURN (-1);
00284 #else
00285   return this->priority_;
00286 #endif /* ACE_HAS_WINSOCK2 */
00287 }

void ACE_Flow_Spec::service_type ACE_SERVICE_TYPE    st
 

Set the service type.

Definition at line 201 of file OS_QoS.cpp.

References ACE_SERVICE_TYPE, and service_type_.

00202 {
00203 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00204     defined (ACE_HAS_WINSOCK2_GQOS)
00205   this->ServiceType = st;
00206 #else
00207   this->service_type_ = st;
00208 #endif /* ACE_HAS_WINSOCK2 */
00209 }

ACE_SERVICE_TYPE ACE_Flow_Spec::service_type void    const
 

Get the service type.

Definition at line 190 of file OS_QoS.cpp.

References service_type_.

Referenced by ACE_Flow_Spec.

00191 {
00192 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00193     defined (ACE_HAS_WINSOCK2_GQOS)
00194   return this->ServiceType;
00195 #else
00196   return this->service_type_;
00197 #endif /* ACE_HAS_WINSOCK2 */
00198 }

void ACE_Flow_Spec::token_bucket_size u_long    tbs
 

Set the token bucket size in bytes.

Definition at line 121 of file OS_QoS.cpp.

References token_bucket_size_.

00122 {
00123 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00124   this->TokenBucketSize = tbs;
00125 #else
00126   this->token_bucket_size_ = tbs;
00127 #endif /* ACE_HAS_WINSOCK2 */
00128 }

u_long ACE_Flow_Spec::token_bucket_size void    const
 

Get the token bucket size in bytes.

Definition at line 111 of file OS_QoS.cpp.

References token_bucket_size_.

Referenced by ACE_Flow_Spec.

00112 {
00113 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00114   return this->TokenBucketSize;
00115 #else
00116   return this->token_bucket_size_;
00117 #endif /* ACE_HAS_WINSOCK2 */
00118 }

void ACE_Flow_Spec::token_rate u_long    tr
 

Set the token rate in bytes/sec.

Definition at line 101 of file OS_QoS.cpp.

References token_rate_.

00102 {
00103 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00104   this->TokenRate = tr;
00105 #else
00106   this->token_rate_ = tr;
00107 #endif /* ACE_HAS_WINSOCK2 */
00108 }

u_long ACE_Flow_Spec::token_rate void    const
 

Get the token rate in bytes/sec.

Definition at line 91 of file OS_QoS.cpp.

References token_rate_.

Referenced by ACE_Flow_Spec.

00092 {
00093 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0)
00094   return this->TokenRate;
00095 #else
00096   return this->token_rate_;
00097 #endif /* ACE_HAS_WINSOCK2 */
00098 }

void ACE_Flow_Spec::ttl int    t
 

Set the time-to-live.

Definition at line 267 of file OS_QoS.cpp.

References ttl_.

00268 {
00269 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00270     defined (ACE_HAS_WINSOCK2_GQOS)
00271   ACE_UNUSED_ARG (t);
00272   // TBD...
00273 #else
00274   this->ttl_ = t;
00275 #endif /* ACE_HAS_WINSOCK2 */
00276 }

int ACE_Flow_Spec::ttl void    const
 

Get the time-to-live.

Definition at line 256 of file OS_QoS.cpp.

References ttl_.

Referenced by ACE_Flow_Spec.

00257 {
00258 #if defined (ACE_HAS_WINSOCK2) && (ACE_HAS_WINSOCK2 != 0) && \
00259     defined (ACE_HAS_WINSOCK2_GQOS)
00260   ACE_NOTSUP_RETURN (-1);
00261 #else
00262   return this->ttl_;
00263 #endif /* ACE_HAS_WINSOCK2 */
00264 }


Member Data Documentation

u_long ACE_Flow_Spec::delay_variation_ [private]
 

Definition at line 190 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and delay_variation.

u_long ACE_Flow_Spec::latency_ [private]
 

Definition at line 189 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and latency.

u_long ACE_Flow_Spec::max_sdu_size_ [private]
 

Definition at line 192 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and max_sdu_size.

u_long ACE_Flow_Spec::minimum_policed_size_ [private]
 

Definition at line 193 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and minimum_policed_size.

u_long ACE_Flow_Spec::peak_bandwidth_ [private]
 

Definition at line 188 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and peak_bandwidth.

int ACE_Flow_Spec::priority_ [private]
 

Definition at line 195 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and priority.

ACE_SERVICE_TYPE ACE_Flow_Spec::service_type_ [private]
 

Definition at line 191 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and service_type.

u_long ACE_Flow_Spec::token_bucket_size_ [private]
 

Definition at line 187 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and token_bucket_size.

u_long ACE_Flow_Spec::token_rate_ [private]
 

Definition at line 186 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and token_rate.

int ACE_Flow_Spec::ttl_ [private]
 

Definition at line 194 of file OS_QoS.h.

Referenced by ACE_Flow_Spec, and ttl.


The documentation for this class was generated from the following files:
Generated on Mon Jun 16 12:48:02 2003 for ACE by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002