#include <qore/common.h>
#include <qore/QoreThreadLock.h>
#include <qore/qore_bitopts.h>
#include <qore/safe_dslist>
#include <time.h>
#include <string.h>
#include <strings.h>
#include <stdlib.h>
#include <stdio.h>
#include <ctype.h>
#include <sys/types.h>
Go to the source code of this file.
Classes | |
class | FeatureList |
STL-like list containing all presently-loaded Qore features. More... | |
struct | qore_option_s |
definition of the elements in the qore_option_list More... | |
Defines | |
#define | _QORE_HAS_QORE_XMLNODE_CLASS 1 |
defined because this version of Qore has the XmlNode Qore class | |
#define | _QORE_HAS_QORE_XMLREADER_CLASS 1 |
defined because this version of Qore has the XmlReader Qore class | |
#define | _QORE_HAS_QORE_XMLDOC_CLASS 1 |
defined because this version of Qore has the XmlDoc Qore class | |
#define | QORE_OPT_ATOMIC_OPERATIONS "atomic operations" |
option: atomic operations | |
#define | QORE_OPT_STACK_GUARD "stack guard" |
option: stack guard | |
#define | QORE_OPT_RUNTIME_STACK_TRACE "runtime stack tracing" |
option: runtime stack tracing | |
#define | QORE_OPT_LIBRARY_DEBUGGING "library debugging" |
option: library debugging | |
#define | QORE_OPT_SHA224 "openssl sha224" |
option: ssh224 algorithm supported (depends on openssl used to compile qore) | |
#define | QORE_OPT_SHA256 "openssl sha256" |
option: ssh256 algorithm supported (depends on openssl used to compile qore) | |
#define | QORE_OPT_SHA384 "openssl sha384" |
option: ssh384 algorithm supported (depends on openssl used to compile qore) | |
#define | QORE_OPT_SHA512 "openssl sha512" |
option: ssh512 algorithm supported (depends on openssl used to compile qore) | |
#define | QORE_OPT_MDC2 "openssl mdc2" |
option: mdc2 algorithm supported (depends on openssl used to compile qore) | |
#define | QORE_OPT_RC5 "openssl rc5" |
option: rc5 algorithm supported (depends on openssl used to compile qore) | |
#define | QORE_OPT_FUNC_ROUND "round()" |
option: round() function available | |
#define | QORE_OPT_FUNC_TIMEGM "timegm()" |
option: timegm() function available | |
#define | QORE_OPT_FUNC_SETEUID "seteuid()" |
option: seteuid() function available | |
#define | QORE_OPT_FUNC_SETEGID "setegid()" |
option: setegid() function available | |
#define | QORE_OPT_FUNC_PARSEXMLWITHSCHEMA "parseXMLWithSchema()" |
option: parseXMLWithSchema() function available (depends on libxml2) | |
#define | QORE_OPT_FUNC_PARSEXMLWITHRELAXNG "parseXMLWithRelaxNG()" |
option: parseXMLWithRelaxNG() function available (depends on libxml2) | |
#define | QO_OPTION 0 |
option type feature | |
Functions | |
DLLEXPORT char * | make_class_name (const char *fn) |
function to try and make a class name out of a file path, returns a new string that must be free()ed | |
DLLEXPORT QoreStringNode * | q_sprintf (const class QoreListNode *params, int field, int offset, class ExceptionSink *xsink) |
a string formatting function that works with Qore data structures | |
DLLEXPORT QoreStringNode * | q_vsprintf (const class QoreListNode *params, int field, int offset, class ExceptionSink *xsink) |
a string formatting function that works with Qore data structures | |
DLLEXPORT struct tm * | q_localtime (const time_t *clock, struct tm *tms) |
thread-safe version of "localtime()" | |
DLLEXPORT struct tm * | q_gmtime (const time_t *clock, struct tm *tms) |
thread-safe version of "gmtime()" | |
DLLEXPORT char * | q_basename (const char *path) |
thread-safe basename function (resulting pointer must be free()ed) | |
DLLEXPORT char * | q_basenameptr (const char *path) |
returns a pointer within the same string | |
DLLEXPORT char * | q_dirname (const char *path) |
thread-safe dirname function (resulting pointer must be free()ed) | |
DLLEXPORT void * | q_realloc (void *ptr, size_t size) |
frees memory if there is an allocation error | |
DLLEXPORT QoreHashNode * | q_getpwuid (uid_t uid) |
thread-safe version of getpwuid(): returns a Qore hash of the passwd information from the uid if possible, otherwise 0 | |
DLLEXPORT QoreHashNode * | q_getpwnam (const char *name) |
thread-safe version of getpwnam(): returns a Qore hash of the passwd information from the username if possible, otherwise 0 | |
DLLEXPORT QoreHashNode * | q_getgrgid (uid_t uid) |
thread-safe version of getgrgid(): returns a Qore hash of the group information from the gid if possible, otherwise 0 | |
DLLEXPORT QoreHashNode * | q_getgrnam (const char *name) |
thread-safe version of getgrnam(): returns a Qore hash of the group information from the group name if possible, otherwise 0 | |
int | q_uname2uid (const char *name, uid_t &uid) |
thread-safe way to lookup a uid from a username | |
int | q_gname2gid (const char *name, gid_t &gid) |
thread-safe way to lookup a gid from a group name | |
DLLEXPORT void | qore_setup_argv (int pos, int argc, char *argv[]) |
sets up the Qore ARGV and QORE_ARGV values | |
DLLEXPORT qore_license_t | qore_get_license () |
returns the license type that the library has been initialized under | |
DLLEXPORT void | qore_exit_process (int rc) |
instead of calling "exit()", call qore_exit_process() to exit without risking a crash if other threads are running | |
static char * | strchrs (const char *str, const char *chars) |
find one of any characters in a string | |
static char * | strnchr (const char *str, int len, char c) |
find a character in a string up to len | |
static void | strtolower (char *str) |
convert a string to lower-case in place | |
static char * | strtoupper (char *str) |
convert a string to upper-case in place | |
DLLEXPORT int | getSecZeroInt (const AbstractQoreNode *a) |
for getting an integer number of seconds, with 0 as the default, from either a relative time value or an integer value | |
DLLEXPORT int64 | getSecZeroBigInt (const AbstractQoreNode *a) |
for getting an integer number of seconds, with 0 as the default, from either a relative time value or an integer value | |
DLLEXPORT int | getSecMinusOneInt (const AbstractQoreNode *a) |
for getting an integer number of seconds, with -1 as the default, from either a relative time value or an integer value | |
DLLEXPORT int64 | getSecMinusOneBigInt (const AbstractQoreNode *a) |
for getting an integer number of seconds, with -1 as the default, from either a relative time value or an integer value | |
DLLEXPORT int | getMsZeroInt (const AbstractQoreNode *a) |
for getting an integer number of milliseconds, with 0 as the default, from either a relative time value or an integer value | |
DLLEXPORT int64 | getMsZeroBigInt (const AbstractQoreNode *a) |
for getting an integer number of milliseconds, with 0 as the default, from either a relative time value or an integer value | |
DLLEXPORT int | getMsMinusOneInt (const AbstractQoreNode *a) |
for getting an integer number of milliseconds, with -1 as the default, from either a relative time value or an integer value | |
DLLEXPORT int64 | getMsMinusOneBigInt (const AbstractQoreNode *a) |
for getting an integer number of milliseconds, with -1 as the default, from either a relative time value or an integer value | |
DLLEXPORT int | getMicroSecZeroInt (const AbstractQoreNode *a) |
for getting an integer number of microseconds, with 0 as the default, from either a relative time value or an integer value | |
static bool | is_nothing (const AbstractQoreNode *n) |
to check if an AbstractQoreNode object is NOTHING | |
static void | discard (AbstractQoreNode *n, ExceptionSink *xsink) |
to deref an AbstractQoreNode (when the pointer may be 0) | |
DLLEXPORT BinaryNode * | qore_deflate (void *ptr, unsigned long len, int level, ExceptionSink *xsink) |
compresses data with the DEFLATE algorithm | |
DLLEXPORT QoreStringNode * | qore_inflate_to_string (const BinaryNode *b, const QoreEncoding *enc, ExceptionSink *xsink) |
decompresses data compressed with the DEFLATE algorithm to a string | |
DLLEXPORT BinaryNode * | qore_inflate_to_binary (const BinaryNode *b, ExceptionSink *xsink) |
decompresses data compressed with the DEFLATE algorithm to a binary | |
DLLEXPORT BinaryNode * | qore_gzip (void *ptr, unsigned long len, int level, ExceptionSink *xsink) |
gzips data | |
DLLEXPORT QoreStringNode * | qore_gunzip_to_string (const BinaryNode *bin, const QoreEncoding *enc, ExceptionSink *xsink) |
gunzips compressed data to a string | |
DLLEXPORT BinaryNode * | qore_gunzip_to_binary (const BinaryNode *bin, ExceptionSink *xsink) |
gunzips compressed data to a binary | |
DLLEXPORT BinaryNode * | qore_bzip2 (void *ptr, unsigned long len, int level, ExceptionSink *xsink) |
compresses data with bzip2 | |
DLLEXPORT QoreStringNode * | qore_bunzip2_to_string (const BinaryNode *bin, const QoreEncoding *enc, ExceptionSink *xsink) |
decompresses bzip2 data to a string | |
DLLEXPORT BinaryNode * | qore_bunzip2_to_binary (const BinaryNode *bin, ExceptionSink *xsink) |
decompresses bzip2 data to a binary | |
Variables | |
DLLEXPORT FeatureList | qoreFeatureList |
list of qore features | |
DLLEXPORT const qore_option_s * | qore_option_list |
list of qore options | |
DLLEXPORT size_t | qore_option_list_size |
number of elements in the option list |
int q_gname2gid | ( | const char * | name, | |
gid_t & | gid | |||
) |
thread-safe way to lookup a gid from a group name
name | the group to look up | |
gid | the gid returned |
int q_uname2uid | ( | const char * | name, | |
uid_t & | uid | |||
) |
thread-safe way to lookup a uid from a username
name | the username to look up | |
uid | the uid returned |