Main Page | Modules | Data Structures | File List | Data Fields

Utilities
[Trend]


Functions

long trend_make_state_color (sos_status_t *state)
char * trend_get_time_breakdown_string (apr_time_t raw_time)
void trend_get_time_breakdown (time_t t, unsigned long *days, unsigned long *hours, unsigned long *minutes, unsigned long *seconds)

Function Documentation

void trend_get_time_breakdown time_t  t,
unsigned long *  days,
unsigned long *  hours,
unsigned long *  minutes,
unsigned long *  seconds
 

Parses a time into its discrete parts, minutes, hours, days, seconds.

Parameters:
t Time object to break apart.
days Receives the number of days.
hours Receives the number of hours.
minutes Receives the number of minutes.
seconds Receives the number of seconds.

char* trend_get_time_breakdown_string apr_time_t  raw_time  ) 
 

Returns a pretty time breakdown in a string.

Parameters:
raw_time Raw time to give a breakdown of.
Returns:
A string containing the time breakdown.

long trend_make_state_color sos_status_t *  state  ) 
 

Calculates a status color given the degree. A status color is a fade between a red color and a green, to indicate health.

Parameters:
state State we're computing the color for, unfortunately we often need a little more information than the degree.
Returns:
The resulting color.


Generated on Wed Apr 28 09:38:38 2004 for State by doxygen 1.3.5