Main Page Modules Class Hierarchy Compound List File List Compound Members File Members

# jutils.h File Reference

## Detailed Description

generic utilities

Definition in file jutils.h.

`#include <stdio.h>`
`#include <string.h>`

Go to the source code of this file.

## Defines
#define | MAX_DEBUG 2
#define | FUNC 2
#define | WARN 1
#define | CHAR_SET(func, var)
#define | INT_SET(func, var)
#define | FLOAT_SET(func, var)
## Functions
void | set_guimsg (GUI *g)
void | MuseSetDebug (int lev)
int | MuseGetDebug ()
void | MuseSetLog (char *file)
void | MuseCloseLog ()
void | notice (const char *format,...)
void | func (const char *format,...)
void | error (const char *format,...)
void | act (const char *format,...)
void | warning (const char *format,...)
double | dtime ()
void | jsleep (int sec, long nsec)
int | set_rtpriority (int max)
void | chomp (char *str)
int | resolve (char *host, char *ip)

## Define Documentation

#define CHAR_SET | ( | func,
|  | var |  | ) |

| Value:
    char var[MAX_VALUE_SIZE]; \
    void func(char *in) { \
    if(strncmp(var,in,MAX_VALUE_SIZE)==0) return; \
    else strncpy(var,in,MAX_VALUE_SIZE); \
    } \
    char *func() { return var; };
Macro declaration of parameters Definition at line 42 of file jutils.h.

#define FLOAT_SET | ( | func,
|  | var |  | ) |

| Value:
    float var; \
    void func(float in) { \
    if(var==in) return; \
    else var=in; \
    } \
    float func() { return var; };
Definition at line 58 of file jutils.h.

#define INT_SET | ( | func,
|  | var |  | ) |

| Value:
    int var; \
    void func(int in) { \
    if(var==in) return; \
    else var=in; \
    } \
    int func() { return var; };
Definition at line 50 of file jutils.h.