| Qore Programming Language Reference Manual 2.2.0

Loading...
Searching...
No Matches
ql_lib.dox.h
1
3 namespace Qore {
5
7 struct NetIfInfo {
9 *string address;
11 *string address_desc;
13 int family;
15 string familystr;
17 string interface;
18};
19}
20
22 namespace Qore {
24
26 struct ExceptionInfo {
28 auto arg;
30 list<hash<CallStackInfo>> callstack;
32 auto desc;
34 int endline;
36 auto err;
38 string file;
40 string lang;
42 int line;
44 hash<ExceptionInfo> next;
46 int offset;
48 string source;
50 string type;
51};
52}
53
55 namespace Qore {
140
142
154nothing abort();
155
157
171 string basename(string path);
172
174
178nothing basename();
179
181
199nothing close_all_fd(*softbool strd);
200
202
216 string dirname(string path);
217
219
223nothing dirname();
224
226
236 int errno();
237
239
249nothing exec(string command);
250
252
264nothing exit(softint rc = 0);
265
267
294 int fork();
295
297
350 list<hash<NetIfInfo>> get_netif_list();
351
353
375 list<hash<auto>> getaddrinfo(*string node, *softstring service, softint family = AF_UNSPEC, softint flags = 0);
376
378
392 int getegid();
393
395
409 int geteuid();
410
412
426 int getgid();
427
429
445 list<int> getgroups();
446
448
472*string gethostbyaddr(string addr, softint type = AF_INET);
473
475
479nothing gethostbyaddr();
480
482
506*hash<auto> gethostbyaddr_long(string addr, softint type = AF_INET);
507
509
513nothing gethostbyaddr_long();
514
516
535*string gethostbyname(string name);
536
538
542nothing gethostbyname();
543
545
564*hash<auto> gethostbyname_long(string name);
565
567
571nothing gethostbyname_long();
572
574
587 string gethostname();
588
590
603 int getpid();
604
606
623 int getppid();
624
626
640 int getuid();
641
643
664 int kill(softint pid, softint sig = SIGHUP);
665
667
674nothing kill();
675
677
687 int qore_add_module_to_blacklist(string name, string msg = "by an API call");
688
690
702 int qore_add_module_to_blacklist_ex(string name, string msg = "by an API call");
703
705
714 int qore_get_library_options();
715
717
729 int qore_set_library_options(int opts);
730
732
749 int rand();
750
752
769 int setegid(softint gid);
770
772
789 int seteuid(softint uid);
790
792
809 int setgid(softint gid);
810
812
828nothing setgroups(softlist<softint> gids);
829
831
844 int setsid();
845
847
864 int setuid(softint uid);
865
867
881 int sleep(softint seconds);
882
884
891nothing sleep();
892
894
910nothing srand(softint seed);
911
913
920nothing srand();
921
923
936 string strerror(softint err);
937
939
952 string strerror();
953
955
975 int system(string command);
976
978
985nothing system();
986
988
1004 int usleep(softint usecs);
1005
1007
1023 int usleep(date d);
1024
1026
1033nothing usleep();
1034
1036}
1037
1039 namespace Qore {
1045
1047 const QLO_DISABLE_GARBAGE_COLLECTION = QLO_DISABLE_GARBAGE_COLLECTION;
1049 const QLO_DISABLE_OPENSSL_CLEANUP = QLO_DISABLE_OPENSSL_CLEANUP;
1051 const QLO_DISABLE_OPENSSL_INIT = QLO_DISABLE_OPENSSL_INIT;
1053 const QLO_DISABLE_SIGNAL_HANDLING = QLO_DISABLE_SIGNAL_HANDLING;
1055
1057 const QLO_DISABLE_TLS_13 = QLO_DISABLE_TLS_13;
1059 const QLO_DO_NOT_SEED_RNG = QLO_DO_NOT_SEED_RNG;
1061
1063 const QLO_MINIMUM_TLS_13 = QLO_MINIMUM_TLS_13;
1065
1068 const QLO_RUNTIME_OPTS = QLO_RUNTIME_OPTS;
1070}
Qore::seconds
date seconds(softint seconds)
Returns a relative date/time value in seconds based on the integer argument passed to be used in date...
Qore::date
date date(date dt)
Returns the date passed.
Qore::basename
nothing basename()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::getppid
int getppid()
Returns the PID (process ID) of the parent process of the current process.
Qore::getaddrinfo
list< hash< auto > > getaddrinfo(*string node, *softstring service, softint family=AF_UNSPEC, softint flags=0)
Returns a list of Address Information Hash for the given node name or string address; if no lookup ca...
Qore::fork
int fork()
Creates a copy of the current process with a new PID.
Qore::usleep
nothing usleep()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::exit
nothing exit(softint rc=0)
Exits the program with the return code passed (this function does not return)
Qore::getegid
int getegid()
Returns the effective group ID of the current process.
Qore::system
nothing system()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::abort
nothing abort()
Aborts the current program (this function does not return)
Qore::dirname
nothing dirname()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::getpid
int getpid()
Returns the PID (process ID) of the current process.
Qore::setsid
int setsid()
Creates a new session lead by the calling process.
Qore::exec
nothing exec(string command)
Replaces the current process image with another; this function does not return.
Qore::setgid
int setgid(softint gid)
Changes the process group ID according to the argument passed.
Qore::seteuid
int seteuid(softint uid)
Changes the effective process user ID according to the argument passed.
Qore::rand
int rand()
Returns a random non-negative 64-bit integer number.
Qore::gethostbyaddr
nothing gethostbyaddr()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::gethostname
string gethostname()
Returns the hostname of the system.
Qore::setegid
int setegid(softint gid)
Changes the process effective group ID according to the argument passed.
Qore::qore_set_library_options
int qore_set_library_options(int opts)
sets Qore runtime library options
Qore::qore_add_module_to_blacklist
int qore_add_module_to_blacklist(string name, string msg="by an API call")
Adds the given module to the blacklist.
Qore::getuid
int getuid()
Returns the real user ID of the current process.
Qore::setgroups
nothing setgroups(softlist< softint > gids)
sets the list of supplementary group IDs for the current process
Qore::gethostbyaddr_long
nothing gethostbyaddr_long()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::getgroups
list< int > getgroups()
returns a list of group IDs that the user is a member of
Qore::close_all_fd
nothing close_all_fd(*softbool strd)
closes all possible file descriptors; useful in "daemon" processes that may have inherited open file ...
Qore::sleep
nothing sleep()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::gethostbyname
nothing gethostbyname()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::errno
int errno()
Returns the error code of the last error that occurred in the current thread.
Qore::qore_add_module_to_blacklist_ex
int qore_add_module_to_blacklist_ex(string name, string msg="by an API call")
Adds the given module to the blacklist and throws an exception if here's an error.
Qore::qore_get_library_options
int qore_get_library_options()
returns all Qore library options
Qore::gethostbyname_long
nothing gethostbyname_long()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::setuid
int setuid(softint uid)
Changes the process user ID according to the argument passed.
Qore::kill
nothing kill()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::strerror
string strerror()
Returns the string corresponding to the last error that occurred in the current thread.
Qore::get_netif_list
list< hash< NetIfInfo > > get_netif_list()
returns a list of network interfaces
Qore::getgid
int getgid()
Returns the real group ID of the current process.
Qore::geteuid
int geteuid()
Returns the effective user ID of the current process.
Qore::srand
nothing srand()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
Qore::QLO_DISABLE_OPENSSL_CLEANUP
const QLO_DISABLE_OPENSSL_CLEANUP
do not perform cleanup on the openssl library (= is cleaned up manually; init only)
Definition ql_lib.dox.h:1049
Qore::QLO_DISABLE_SIGNAL_HANDLING
const QLO_DISABLE_SIGNAL_HANDLING
disable qore signal handling entirely (init only)
Definition ql_lib.dox.h:1053
Qore::QLO_RUNTIME_OPTS
const QLO_RUNTIME_OPTS
bitmask for library options that can be set at runtime
Definition ql_lib.dox.h:1068
Qore::QLO_DISABLE_GARBAGE_COLLECTION
const QLO_DISABLE_GARBAGE_COLLECTION
disable garbage collection / recursive object reference detection (init only)
Definition ql_lib.dox.h:1047
Qore::QLO_DISABLE_TLS_13
const QLO_DISABLE_TLS_13
disable TLS v1.3 (may be set at runtime with qore_set_library_options())
Definition ql_lib.dox.h:1057
Qore::QLO_MINIMUM_TLS_13
const QLO_MINIMUM_TLS_13
enable minimum TLS v1.3 (may be set at runtime with qore_set_library_options())
Definition ql_lib.dox.h:1063
Qore::QLO_DISABLE_OPENSSL_INIT
const QLO_DISABLE_OPENSSL_INIT
do not initialize the openssl library (= is initialized before the qore library is initialized; init ...
Definition ql_lib.dox.h:1051
Qore::QLO_DO_NOT_SEED_RNG
const QLO_DO_NOT_SEED_RNG
disable seeding the random number generator when the Qore library is initialized (init only)
Definition ql_lib.dox.h:1059
Qore::AF_UNSPEC
const AF_UNSPEC
unspecified address family
Definition QC_Socket.dox.h:3291
Qore::AF_INET
const AF_INET
IPv4 address family.
Definition QC_Socket.dox.h:3283
Qore::SIGHUP
const SIGHUP
SIGHUP.
Definition ql_misc.dox.h:2579
Qore::type
string type(auto arg)
Returns a string giving the data type of the argument passed; see String Type Constants for the value...
Qore::hash
hash< auto > hash(object obj)
Returns a hash of an object's members.
Qore::list
list< auto > list(...)
Returns a list of the arguments passed at the top level.
Qore
main Qore-language namespace
Definition Pseudo_QC_All.dox.h:3
Qore::ExceptionInfo
exception information hash
Definition ql_lib.dox.h:26
Qore::ExceptionInfo::callstack
list< hash< CallStackInfo > > callstack
call stack backtrace information
Definition ql_lib.dox.h:30
Qore::ExceptionInfo::next
hash< ExceptionInfo > next
chained exception info
Definition ql_lib.dox.h:44
Qore::ExceptionInfo::arg
auto arg
this key is populated with the value of the third expression of the throw statement (if a list was th...
Definition ql_lib.dox.h:28
Qore::ExceptionInfo::desc
auto desc
this key is populated with the value of the second expression of the throw statement (if a list was t...
Definition ql_lib.dox.h:32
Qore::ExceptionInfo::offset
int offset
position info: line number offset for the "source" key (if known, for user code only)
Definition ql_lib.dox.h:46
Qore::ExceptionInfo::err
auto err
this key is populated with the value of the first expression of the throw statement....
Definition ql_lib.dox.h:36
Qore::ExceptionInfo::line
int line
position info: start line number
Definition ql_lib.dox.h:42
Qore::ExceptionInfo::file
string file
position info: the parse label where exception occurred; this is normally the file name; this corresp...
Definition ql_lib.dox.h:38
Qore::ExceptionInfo::source
string source
position info: an optional source string; if multiple sections of a file were parsed with different p...
Definition ql_lib.dox.h:48
Qore::ExceptionInfo::endline
int endline
position info: end line number
Definition ql_lib.dox.h:34
Qore::ExceptionInfo::type
string type
exception type: "User" or "System"; see Exception Type Constants
Definition ql_lib.dox.h:50
Qore::ExceptionInfo::lang
string lang
the language of the source code location; normally "Qore"
Definition ql_lib.dox.h:40
Qore::NetIfInfo
network interface info hash
Definition ql_lib.dox.h:7
Qore::NetIfInfo::family
int family
interface family type; see Network Address Family Constants for possible values
Definition ql_lib.dox.h:13
Qore::NetIfInfo::address
*string address
interface address if available
Definition ql_lib.dox.h:9
Qore::NetIfInfo::familystr
string familystr
interface family type string
Definition ql_lib.dox.h:15
Qore::NetIfInfo::interface
string interface
interface name
Definition ql_lib.dox.h:17
Qore::NetIfInfo::address_desc
*string address_desc
interface address description (if the address is available)
Definition ql_lib.dox.h:11