|
rpm
5.4.14
|

Go to the source code of this file.
Macros | |
| #define | _RPMRUBY_INTERNAL 1 |
Functions | |
| static void | rpmrubyFini (void *_ruby) |
| Finalizes a Ruby interpreter instance/pool item. More... | |
| static rpmruby | rpmrubyGetPool (rpmioPool pool) |
| Returns the current rpmio pool responsible for Ruby interpreter instances. More... | |
| static rpmruby | rpmrubyI (void) |
| rpmruby | rpmrubyNew (char **av, uint32_t flags) |
| Creates and initializes a Ruby interpreter. More... | |
| rpmRC | rpmrubyRun (rpmruby ruby, const char *str, const char **resultp) |
| Evaluates Ruby code stored in a string. More... | |
Variables | |
| int | _rpmruby_debug = 0 |
| Triggers printing of debugging information. More... | |
| rpmruby | _rpmrubyI = NULL |
| Current (global) interpreter instance. More... | |
| rpmioPool | _rpmrubyPool |
| The pool of Ruby interpreter instances. More... | |
Finalizes a Ruby interpreter instance/pool item.
Definition at line 37 of file rpmruby.c.
References NULL.
Referenced by rpmrubyGetPool().
Returns the current rpmio pool responsible for Ruby interpreter instances.
This is a wrapper function that returns the current rpmio pool responsible for embedded Ruby interpreters. It creates and initializes a new pool when there is no current pool.
Definition at line 66 of file rpmruby.c.
References _rpmruby_debug, _rpmrubyPool, NULL, rpmioGetPool(), rpmioNewPool(), and rpmrubyFini().
Referenced by rpmrubyNew().
Definition at line 90 of file rpmruby.c.
References _rpmrubyI, NULL, and rpmrubyNew().
Referenced by rpmrubyRun().
| rpmruby rpmrubyNew | ( | char ** | av, |
| uint32_t | flags | ||
| ) |
Creates and initializes a Ruby interpreter.
| av | Arguments to the Ruby interpreter (may be NULL) |
| flags | Ruby interpreter flags: ((1<<31): use global interpreter) |
Definition at line 99 of file rpmruby.c.
References _rpmrubyI, NULL, rpmrubyGetPool(), rpmrubyLink(), rpmrubyRun(), and void.
Referenced by rpmrubyI(), and while().
Evaluates Ruby code stored in a string.
| ruby | The Ruby interpreter that is to be used (NULL uses global interpreter) |
| str | Ruby code to evaluate (NULL forces return of RPMRC_FAIL) |
| *resultp | Result of the evaluation |
Definition at line 126 of file rpmruby.c.
References _rpmruby_debug, fprintf(), NULL, rc, RPMRC_FAIL, RPMRC_OK, and rpmrubyI().
Referenced by rpmrbLoadClasses(), rpmrbLoadFile(), rpmrubyNew(), and while().
| int _rpmruby_debug = 0 |
Triggers printing of debugging information.
Definition at line 29 of file rpmruby.c.
Referenced by main(), rpmrubyGetPool(), and rpmrubyRun().
Current (global) interpreter instance.
At the moment, this variable is merely a safeguard against initializing the Ruby interpreter over and over again. In the future, when there is Ruby support for multiple interpreter instances, a flag given to rpmrubyNew() will use this variable and return the global interpreter instance.
| rpmioPool _rpmrubyPool |
The pool of Ruby interpreter instances.
Definition at line 54 of file rpmruby.c.
Referenced by rpmioClean(), and rpmrubyGetPool().
1.8.5