1 #ifndef THROUGHPUT_COUNTER_CLASS
2 #define THROUGHPUT_COUNTER_CLASS
60 void send(
double size_of_send);
65 void add_run(
double size_of_send,
double time_of_send,
66 double number_of_runs = 1.0);
105 double _time_overall;
Reports on average bandwidth of the transfers being measured.
double kilobytes_per_second() const
returns the number of kilobytes that transfers are getting per second.
double bytes_sent() const
returns the number of bytes sent so far.
void reset()
clears all statistics and starts over.
void stop()
ends the current run.
double total_time() const
the run time so far, in milliseconds.
bool running() const
returns whether a test run is being worked on or not.
double number_of_sends() const
returns the number of sends that have occurred.
void send(double size_of_send)
records a sending of "size_of_send" bytes.
throughput_counter & operator=(const throughput_counter &to_copy)
double bytes_per_second() const
returns the number of bytes that transfers are getting per second.
timely::time_stamp stop_time() const
reports the time when this run was stopped.
timely::time_stamp start_time() const
reports the time when this run started.
double megabytes_per_second() const
returns the number of megabytes that transfers are getting per second.
void start()
begins timing a run.
void combine(const throughput_counter &to_blend)
incorporates the statistics from "to_blend" into this counter.
void add_run(double size_of_send, double time_of_send, double number_of_runs=1.0)
records a run without changing the state of the current run.
Represents a point in time relative to the operating system startup time.
Provides access to the operating system's socket methods.