Linuxpops  3.01.04
Spectral Anaysis Package for Single Dish Data
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
utils.h File Reference
#include <sys/types.h>

Go to the source code of this file.

Macros

#define PAD(bits, pad)   (((bits)+(pad)-1)&-(pad))
 
#define MIN2(a, b)   (((a) < (b)) ? a : b)
 
#define MAX2(a, b)   (((a) > (b)) ? a : b)
 
#define MIN3(a, b, c)   (((a) < (b)) ? MIN2(a, c) : MIN2(b, c))
 
#define MAX3(a, b, c)   (((a) > (b)) ? MAX2(a, c) : MAX2(b, c))
 
#define yes_or_no(x)   ((x)?"yes":"no")
 
#define on_or_off(x)   ((x)?"on":"off")
 
#define true_or_false(x)   ((x)?"true":"false")
 
#define w_or_v(x)   ((x == COORD_WORLD)?"world":"view")
 
#define LFORMAT_TYPE_PLAIN   0
 
#define LFORMAT_TYPE_EXTENDED   1
 
#define cxfree(ptr)   xfree(ptr); ptr = NULL
 
#define PSTRING(s)   ((s == NULL) ? "" : escapequotes(s))
 

Functions

void xfree (void *ptr)
 
void * xrealloc (void *ptr, size_t size)
 
void fswap (double *x, double *y)
 
void iswap (int *x, int *y)
 
int isoneof (int c, char *s)
 
int argmatch (char *s1, char *s2, int atleast)
 
void lowtoupper (char *s)
 
void convertchar (char *s)
 
int ilog2 (int n)
 
double comp_area (int n, double *x, double *y)
 
double comp_perimeter (int n, double *x, double *y)
 
char * create_fstring (int form, int prec, double loc, int type)
 
char * escapequotes (char *s)
 
int sign (double a)
 
double mytrunc (double a)
 
void bailout (void)
 
void installSignal (void)
 
int bin_dump (char *value, int i, int pad)
 
unsigned char reversebits (unsigned char inword)
 
char * copy_string (char *dest, const char *src)
 
char * concat_strings (char *dest, const char *src)
 
int compare_strings (const char *s1, const char *s2)
 
void reverse_string (char *s)
 
char * get_grace_home (void)
 
void set_grace_home (const char *dir)
 
char * get_help_viewer (void)
 
void set_help_viewer (const char *dir)
 
char * get_print_cmd (void)
 
void set_print_cmd (const char *cmd)
 
char * get_editor (void)
 
void set_editor (const char *cmd)
 
char * get_docname (void)
 
void set_docname (const char *s)
 
void errmsg (char *buf)
 
void echomsg (char *msg)
 
void stufftext (char *s, int sp)
 
void log_results (char *buf)
 
int yesnoterm (char *msg)
 
int yesno (char *msg, char *s1, char *s2, char *help_anchor)
 
int fexists (const char *to)
 
char * mybasename (const char *s)
 
void expand_tilde (char *buf)
 
int set_workingdir (const char *wd)
 
char * get_workingdir (void)
 
void init_username (void)
 
char * get_username (void)
 
void init_userhome (void)
 
char * get_userhome (void)
 
void update_app_title (void)
 
void set_dirtystate (void)
 
void clear_dirtystate (void)
 
void lock_dirtystate (int flag)
 
int is_dirtystate (void)
 
int system_wrap (const char *string)
 
void msleep_wrap (unsigned int msec)
 
int init_locale (void)
 
void set_locale_num (int flag)
 
long bi_version_id (void)
 
char * bi_version_string (void)
 
char * bi_system (void)
 
char * bi_date (void)
 
char * bi_gui (void)
 
char * bi_ccompiler (void)
 
char * bi_t1lib (void)
 

Macro Definition Documentation

#define cxfree (   ptr)    xfree(ptr); ptr = NULL

Definition at line 50 of file utils.h.

#define LFORMAT_TYPE_EXTENDED   1

Definition at line 48 of file utils.h.

#define LFORMAT_TYPE_PLAIN   0

Definition at line 47 of file utils.h.

#define MAX2 (   a,
  b 
)    (((a) > (b)) ? a : b)

Definition at line 38 of file utils.h.

#define MAX3 (   a,
  b,
  c 
)    (((a) > (b)) ? MAX2(a, c) : MAX2(b, c))

Definition at line 40 of file utils.h.

#define MIN2 (   a,
  b 
)    (((a) < (b)) ? a : b)

Definition at line 37 of file utils.h.

#define MIN3 (   a,
  b,
  c 
)    (((a) < (b)) ? MIN2(a, c) : MIN2(b, c))

Definition at line 39 of file utils.h.

#define on_or_off (   x)    ((x)?"on":"off")

Definition at line 43 of file utils.h.

#define PAD (   bits,
  pad 
)    (((bits)+(pad)-1)&-(pad))

Definition at line 35 of file utils.h.

#define PSTRING (   s)    ((s == NULL) ? "" : escapequotes(s))

Definition at line 52 of file utils.h.

#define true_or_false (   x)    ((x)?"true":"false")

Definition at line 44 of file utils.h.

#define w_or_v (   x)    ((x == COORD_WORLD)?"world":"view")

Definition at line 45 of file utils.h.

#define yes_or_no (   x)    ((x)?"yes":"no")

Definition at line 42 of file utils.h.

Function Documentation

int argmatch ( char *  s1,
char *  s2,
int  atleast 
)

Definition at line 559 of file dataserv.c.

void bailout ( void  )
char* bi_ccompiler ( void  )
char* bi_date ( void  )
char* bi_gui ( void  )
char* bi_system ( void  )
char* bi_t1lib ( void  )
long bi_version_id ( void  )
char* bi_version_string ( void  )
int bin_dump ( char *  value,
int  i,
int  pad 
)
void clear_dirtystate ( void  )
double comp_area ( int  n,
double *  x,
double *  y 
)
double comp_perimeter ( int  n,
double *  x,
double *  y 
)
int compare_strings ( const char *  s1,
const char *  s2 
)
char* concat_strings ( char *  dest,
const char *  src 
)
void convertchar ( char *  s)
char* copy_string ( char *  dest,
const char *  src 
)
char* create_fstring ( int  form,
int  prec,
double  loc,
int  type 
)
void echomsg ( char *  msg)
void errmsg ( char *  buf)
char* escapequotes ( char *  s)
void expand_tilde ( char *  buf)
int fexists ( const char *  to)
void fswap ( double *  x,
double *  y 
)
char* get_docname ( void  )
char* get_editor ( void  )
char* get_grace_home ( void  )
char* get_help_viewer ( void  )
char* get_print_cmd ( void  )
char* get_userhome ( void  )
char* get_username ( void  )
char* get_workingdir ( void  )
int ilog2 ( int  n)
int init_locale ( void  )
void init_userhome ( void  )
void init_username ( void  )
void installSignal ( void  )
int is_dirtystate ( void  )
int isoneof ( int  c,
char *  s 
)
void iswap ( int *  x,
int *  y 
)
void lock_dirtystate ( int  flag)
void log_results ( char *  buf)
void lowtoupper ( char *  s)
void msleep_wrap ( unsigned int  msec)
char* mybasename ( const char *  s)
double mytrunc ( double  a)
void reverse_string ( char *  s)
unsigned char reversebits ( unsigned char  inword)
void set_dirtystate ( void  )
void set_docname ( const char *  s)
void set_editor ( const char *  cmd)
void set_grace_home ( const char *  dir)
void set_help_viewer ( const char *  dir)
void set_locale_num ( int  flag)
void set_print_cmd ( const char *  cmd)
int set_workingdir ( const char *  wd)
int sign ( double  a)
void stufftext ( char *  s,
int  sp 
)
int system_wrap ( const char *  string)
void update_app_title ( void  )
void xfree ( void *  ptr)

Definition at line 122 of file grace_fit.c.

void* xrealloc ( void *  ptr,
size_t  size 
)
int yesno ( char *  msg,
char *  s1,
char *  s2,
char *  help_anchor 
)
int yesnoterm ( char *  msg)