Ruby 2.7.0p0(2019-12-25revision647ee6f091eafcce70ffb75ddf7e121e192ab217)

Macros | Functions
syslog.c File Reference
`#include "ruby/ruby.h"`
`#include "ruby/util.h"`
`#include <syslog.h>`

Go to the source code of this file.

## Macros
#define | define_syslog_shortcut_method(pri, name)
#define | rb_define_syslog_option(c) rb_define_const(mSyslogOption, #c, INT2NUM(c))
#define | rb_define_syslog_facility(c) rb_define_const(mSyslogFacility, #c, INT2NUM(c))
#define | rb_define_syslog_level(c, m)

## Functions
void | Init_syslog (void)

## Macro Definition Documentation

## ◆ define_syslog_shortcut_method

#define define_syslog_shortcut_method | ( |  | pri,
|  |  | name
| ) |  |

Value:
static VALUE mSyslog_##name(int argc, VALUE *argv, VALUE self) \
{ \
syslog_write((pri), argc, argv); \
\
return self; \
}

Definition at line 342 of file syslog.c.

## ◆ rb_define_syslog_facility

#define rb_define_syslog_facility | ( |  | c | ) | rb_define_const(mSyslogFacility, #c, INT2NUM(c))

## ◆ rb_define_syslog_level

#define rb_define_syslog_level | ( |  | c,
|  |  | m
| ) |  |

Value:
rb_define_const(mSyslogLevel, #c, INT2NUM(c)); \
rb_define_module_function(mSyslog, #m, mSyslog_##m, -1)

## ◆ rb_define_syslog_option

#define rb_define_syslog_option | ( |  | c | ) | rb_define_const(mSyslogOption, #c, INT2NUM(c))

## Function Documentation

## ◆ Init_syslog()

void Init_syslog | ( | void |  | ) |

Definition at line 416 of file syslog.c.

VALUE
unsigned long VALUE
Definition: ruby.h:102
INT2NUM
#define INT2NUM(x)
Definition: ruby.h:1609
argv
char ** argv
Definition: ruby.c:223
argc
int argc
Definition: ruby.c:222
rb_define_const
void rb_define_const(VALUE, const char *, VALUE)
Definition: variable.c:2880
name
const char * name
Definition: nkf.c:208