Qore Programming Language Reference Manual 2.2.0
Loading...
Searching...
No Matches
ql_misc.dox.h
1
3namespace Qore {
5
7hashdecl UrlInfo {
9 string host;
11 string password;
13 string path;
15 int port;
17 string protocol;
19 string query;
21 string username;
22};
23}
24
26namespace Qore {
31
33
52
54
76
78}
79
81namespace Qore {
86
88
111
113
121
123
140auto call_builtin_function(string name, ...);
141
143
161
163
185auto call_function(string name, ...);
186
188
205auto call_function(code f, ...);
206
208
231
233
251
253
292string decode_uri_request(string uri);
293
295
314string decode_url(string url);
315
317
322
324
355string encode_uri_request(string url);
356
358
379
381
393bool exists( ...);
394
396
405bool existsFunction(string name);
406
408
419bool existsFunction(code c);
420
422
427
429
443bool exists_function(string name);
444
446
458
460
468__7_ string functionType(string name);
469
471
476
478
488__7_ string function_type(string name);
489
491
504__7_ int getByte(string str, softint offset = 0);
505
507
512
514
527__7_ int getByte(binary b, softint offset = 0);
528
530
538string getClassName(object obj);
539
541
546
548
558
560
581
583
604
606
620__7_ int getWord32(string str, softint offset = 0);
621
623
637__7_ int getWord32(binary b, softint offset = 0);
638
640
645
647
663__7_ int get_byte(string str, softint offset = 0);
664
666
682__7_ int get_byte(binary b, softint offset = 0);
683
685
712
714
729string get_class_name(object obj);
730
732
740
742
761
763
775
777
792
794
816
818
829
831
844
846
857
859
872
874
895
897
920
922
942auto get_module_option(string module, string option);
943
945
958
960
983
985
1004
1006
1023
1025
1031string get_safe_url(string url);
1032
1034
1042
1044
1052
1054
1062
1064
1081__7_ int get_word_16(string str, softint offset = 0);
1082
1084
1102
1104
1121__7_ int get_word_16_lsb(string str, softint offset = 0);
1122
1124
1142
1144
1163__7_ int get_word_32(string str, softint offset = 0);
1164
1166
1186
1188
1207__7_ int get_word_32_lsb(string str, softint offset = 0);
1208
1210
1228
1230
1247__7_ int get_word_64(string str, softint offset = 0);
1248
1250
1268
1270
1287__7_ int get_word_64_lsb(string str, softint offset = 0);
1288
1290
1308
1310
1324bool has_key(hash<auto> h, string key);
1325
1327
1336bool has_key(object obj, string key);
1337
1339
1356
1358
1363
1365
1376int hextoint(string str);
1377
1379
1384
1386
1402string html_decode(string str);
1403
1405
1410
1412
1428string html_encode(string str);
1429
1431
1436
1438
1464
1466
1474
1476
1502
1504
1522
1524
1543
1545
1564
1566
1571
1573
1587string makeHexString(string str);
1588
1590
1605
1607
1612
1614
1636
1638
1660
1662
1682
1684
1704
1706
1725string make_hex_string(string str);
1726
1728
1748
1750
1775__7_ hash<auto> parse(string code, string label, __7_ softint warning_mask, __7_ string source, __7_ softint offset, softbool format_label = True);
1776
1778
1786
1788
1806
1808
1813
1815
1835string parseBase64StringToString(string str, __7_ string encoding);
1836
1838
1843
1845
1861
1863
1868
1870
1911
1913
1918
1920
1943
1945
1970string parse_base64_string_to_string(string str, __7_ string encoding);
1971
1973
1995
1997
2019string parse_base64_url_string_to_string(string str, __7_ string encoding);
2020
2022
2043
2045
2086
2088
2128
2130
2152
2154
2171
2173
2194
2196
2213
2215
2230
2232
2241string splice(string str);
2242
2244
2258string splice(string str, softint start);
2259
2261
2277string splice(string str, softint start, softint len, __7_ string nstr);
2278
2280
2293
2295
2311
2313
2330
2332
2337
2339
2351int strtoint(string num, softint base = 10);
2352
2354
2359
2361}
2362
2364namespace Qore {
2370
2376
2381
2385}
2386
2388namespace Qore {
2396
2398
2402
2410
2416
2422
2435}
2436
2438namespace Qore {
2446
2448
2452
2460
2464
2470
2483}
2484
2486namespace Qore {
2491
2494 "SIGABRT": SIGABRT,
2495 "SIGALRM": SIGALRM,
2496 "SIGBUS": SIGBUS,
2497 "SIGCANCEL": SIGCANCEL,
2498 "SIGCHLD": SIGCHLD,
2499 "SIGCLD": SIGCLD,
2500 "SIGCONT": SIGCONT,
2501 "SIGEMT": SIGEMT,
2502 "SIGFPE": SIGFPE,
2503 "SIGFREEZE": SIGFREEZE,
2504 "SIGHUP": SIGHUP,
2505 "SIGILL": SIGILL,
2506 "SIGINFO": SIGINFO,
2507 "SIGINT": SIGINT,
2508 "SIGIO": SIGIO,
2509 "SIGIOT": SIGIOT,
2510 "SIGJVM1": SIGJVM1,
2511 "SIGJVM2": SIGJVM2,
2512 "SIGKILL": SIGKILL,
2513 "SIGLOST": SIGLOST,
2514 "SIGLWP": SIGLWP,
2515 "SIGPIPE": SIGPIPE,
2516 "SIGPOLL": SIGPOLL,
2517 "SIGPROF": SIGPROF,
2518 "SIGPWR": SIGPWR,
2519 "SIGQUIT": SIGQUIT,
2520 "SIGSEGV": SIGSEGV,
2521 "SIGSTKFLT": SIGSTKFLT,
2522 "SIGSTOP": SIGSTOP,
2523 "SIGSYS": SIGSYS,
2524 "SIGTERM": SIGTERM,
2525 "SIGTHAW": SIGTHAW,
2526 "SIGTRAP": SIGTRAP,
2527 "SIGTSTP": SIGTSTP,
2528 "SIGTTIN": SIGTTIN,
2529 "SIGTTOU": SIGTTOU,
2530 "SIGURG": SIGURG,
2531 "SIGUSR1": SIGUSR1,
2532 "SIGUSR2": SIGUSR2,
2533 "SIGVTALRM": SIGVTALRM,
2534 "SIGWAITING": SIGWAITING,
2535 "SIGWINCH": SIGWINCH,
2536 "SIGXCPU": SIGXCPU,
2537 "SIGXFSZ": SIGXFSZ,
2538 "SIGXRES": SIGXRES,
2539);
2569 const SIGIO = SIGIO;
2632 SIGABRT: "SIGABRT",
2633 SIGALRM: "SIGALRM",
2634 SIGBUS: "SIGBUS",
2635 SIGCANCEL: "SIGCANCEL",
2636 SIGCHLD: "SIGCHLD",
2637 SIGCONT: "SIGCONT",
2638 SIGEMT: "SIGEMT",
2639 SIGFPE: "SIGFPE",
2640 SIGFREEZE: "SIGFREEZE",
2641 SIGHUP: "SIGHUP",
2642 SIGILL: "SIGILL",
2643 SIGINFO: "SIGINFO",
2644 SIGINT: "SIGINT",
2645 SIGIO: "SIGIO",
2646 SIGIOT: "SIGIOT",
2647 SIGJVM1: "SIGJVM1",
2648 SIGJVM2: "SIGJVM2",
2649 SIGKILL: "SIGKILL",
2650 SIGLOST: "SIGLOST",
2651 SIGLWP: "SIGLWP",
2652 SIGPIPE: "SIGPIPE",
2653 SIGPOLL: "SIGPOLL",
2654 SIGPROF: "SIGPROF",
2655 SIGPWR: "SIGPWR",
2656 SIGQUIT: "SIGQUIT",
2657 SIGSEGV: "SIGSEGV",
2658 SIGSTKSZ: "SIGSTKSZ",
2659 SIGSTOP: "SIGSTOP",
2660 SIGSYS: "SIGSYS",
2661 SIGTERM: "SIGTERM",
2662 SIGTHAW: "SIGTHAW",
2663 SIGTRAP: "SIGTRAP",
2664 SIGTSTP: "SIGTSTP",
2665 SIGTTIN: "SIGTTIN",
2666 SIGTTOU: "SIGTTOU",
2667 SIGURG: "SIGURG",
2668 SIGUSR1: "SIGUSR1",
2669 SIGUSR2: "SIGUSR2",
2670 SIGVTALRM: "SIGVTALRM",
2671 SIGWAITING: "SIGWAITING",
2672 SIGWINCH: "SIGWINCH",
2673 SIGXCPU: "SIGXCPU",
2674 SIGXFSZ: "SIGXFSZ",
2675 SIGXRES: "SIGXRES",
2676);
2678}
Program objects allow Qore programs to support subprograms with the option to restrict capabilities,...
Definition QC_Program.dox.h:56
const CD_XML
code for decoding XML entities
Definition ql_misc.dox.h:2481
const CD_ALL
code for decoding everything
Definition ql_misc.dox.h:2450
const CD_XHTML
code for decoding XHTML named character references to symbols
Definition ql_misc.dox.h:2468
const CD_NUM_REF
code for decoding numeric character references to symbols
Definition ql_misc.dox.h:2462
const CD_HTML
code for decoding HTML 5 named character references to their native symbols
Definition ql_misc.dox.h:2458
const CE_ALL
code for encoding everything
Definition ql_misc.dox.h:2400
const CE_HTML
code for encoding HTML 5 symbols as named character references
Definition ql_misc.dox.h:2408
const CE_NONASCII
code for encoding all non-ASCII symbols as numeric character references
Definition ql_misc.dox.h:2414
const CE_XHTML
code for encoding XHTML entities
Definition ql_misc.dox.h:2420
const CE_XML
code for encoding XML entities
Definition ql_misc.dox.h:2433
const True
logical True
Definition qc_qore.dox.h:98
const False
logical False
Definition qc_qore.dox.h:96
string parse_base64_string_to_string(string str, *string encoding)
Parses a base64 encoded string and returns a string of the decoded data.
string get_module_context_name_ex()
Returns the name of the module currently being loaded.
nothing parseBase64String()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
nothing getWord32()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
hash< string, hash< auto > > get_qore_option_hash()
Returns a hash of hashes giving information about Qore library options for the current build.
string get_safe_url(string url)
Returns the URL string passed without any password information.
auto call_function_args(string name, *softlist< auto > vargs)
Calls a function and returns the return value, using the optional second argument as a list of argume...
hash< UrlInfo > parse_url(string url, bool keep_brackets)
Parses a URL string and returns a hash of the components.
nothing makeBase64String()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
nothing backquote()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
nothing set_local_var_value(int frame, string var, auto value)
sets the value of the given local variable; if the variable cannot be found an exception is raised
*string function_type(string name)
Returns "builtin" (for a builtin function), "user" (for a user function), or NOTHING (if the function...
*int get_byte(string str, softint offset=0)
Returns the byte value at the given byte offset (the first value is at offset 0) or NOTHING if the of...
nothing strtoint()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
auto get_module_option(string module, string option)
returns the given global module option
nothing html_encode()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
*int get_word_32_lsb(string str, softint offset=0)
Returns the 32-bit integer value at the given 4-byte offset (the first value is at offset 0) or NOTHI...
auto call_builtin_function(string name,...)
Calls a function and returns the return value, passing the remaining arguments after the function nam...
nothing decode_url()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
hash< auto > get_local_vars(int frame)
retrieves a hash of local variables for the given stack frame
binary parse_base64_string(string str)
Parses a base64 encoded string and returns a binary object of the decoded data.
nothing load_module()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
bool exists_function(string name)
Returns True if the function exists in the current program's function name space.
*string get_script_path()
Returns the path (directory and filename) of the current script or NOTHING if unknown (i....
*string get_script_dir()
Returns the name of the directory from which the current script was executed or NOTHING if unknown (i...
*string get_module_context_path()
Returns the path of the module currently being loaded, if any.
list< string > getFeatureList()
Returns a list of strings of the builtin and module-supplied features of Qore.
auto call_builtin_function_args(string name, *softlist< auto > vargs)
Calls a function and returns the return value, using the optional second argument as a list of argume...
string parse_base64_url_string_to_string(string str, *string encoding)
Parses a base64-url-encoded string and returns a string of the decoded data.
set_return_value(auto val)
sets the return value for a Program object when running with %exec-class
nothing hextoint()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
binary parse_base64_url_string(string str)
Parses a base64-url-encoded string and returns a binary object of the decoded data.
*hash< ExceptionInfo > load_module_warn(string name, int warning_mask=WARN_MODULES)
Loads in a Qore module at run-time.
*int get_word_16(string str, softint offset=0)
Returns the 16-bit integer value at the given 2-byte offset (the first value is at offset 0) or NOTHI...
list< hash< auto > > get_module_list()
Returns a list of hashes describing the currently-loaded Qore modules.
nothing load_user_module_with_program(string name, Qore::Program pgm)
Loads in a Qore user module at run-time with using the given Program object as the container for the ...
string encode_url(string url, softbool encode_all=False)
Encodes URLs by substituting '%' characters with '%25', spaces (' ') with '%20', and non-ascii charac...
nothing parseHexString()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
nothing getClassName()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
int get_parse_options()
returns the current parse options for the current Program object
code get_call_reference(string identifier)
resolve the string as a call reference
nothing parse()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
bool has_key(hash< auto > h, string key)
Returns True if the given key exists in the hash (does not necessarily have to have a value assigned)...
nothing hash_values()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
nothing splice()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
list< hash< auto > > get_qore_option_list()
Returns a list of hashes giving information about Qore library options for the current build.
auto call_function(string name,...)
Calls a function and returns the return value, passing the remaining arguments after the function nam...
nothing reload_module(string name)
Reloads an already-loaded Qore module subject to code injection at run-time into Qore; the module's c...
nothing parseBase64StringToString()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
*int get_word_16_lsb(string str, softint offset=0)
Returns the 16-bit integer value at the given 2-byte offset (the first value is at offset 0) or NOTHI...
string make_base64_string(string str, softint maxlinelen=-1)
Returns a base64-encoded representation of a string.
string get_default_encoding()
Returns the name of the default character encoding.
nothing set_module_option(string module, string option, auto value)
set the given module option
hash< string, hash< auto > > get_module_hash()
Returns a hash of hashes describing the currently-loaded Qore modules; the top-level hash keys are th...
list< string > get_feature_list()
Returns a list of strings of the builtin and module-supplied features of Qore.
string get_class_name(object obj)
Returns the class name of the object passed.
string get_ex_pos(hash< auto > ex)
returns a descriptive string for an exception location; the source and offset information will also b...
*string get_module_context_name()
Returns the name of the module currently being loaded, if any.
string get_module_context_path_ex()
Returns the path of the module currently being loaded.
hash< string, hash< auto > > getModuleHash()
Returns a hash of hashes describing the currently-loaded Qore modules; the top-level hash keys are th...
string make_base64_url_string(string str)
Returns a base64-url-encoded representation of a string.
*int get_word_64_lsb(string str, softint offset=0)
Returns the 64-bit integer value at the given 8-byte offset (the first value is at offset 0) or NOTHI...
nothing existsFunction()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
nothing makeHexString()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
list< hash< auto > > getModuleList()
Returns a list of hashes describing the currently-loaded Qore modules.
hash< auto > get_global_vars()
returns a hash of global variables
string encode_uri_request(string url)
Encodes URI requests by substituting special characters in the path with percent-encoded equivalents ...
bool exists(...)
A function performing the same role as the exists operator.
nothing parseURL()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
nothing html_decode()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
*string get_script_name()
Returns the filename of the current script if known or NOTHING if unknown (i.e. no parent script,...
*int get_word_64(string str, softint offset=0)
Returns the 64-bit integer value at the given 8-byte offset (the first value is at offset 0) or NOTHI...
nothing getByte()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
hash< auto > get_qore_library_info()
Returns a hash of library build and version info.
*int get_word_32(string str, softint offset=0)
Returns the 32-bit integer value at the given 4-byte offset (the first value is at offset 0) or NOTHI...
string make_hex_string(string str)
Returns a hex-encoded representation of a string.
nothing set_global_var_value(string name, auto value)
set the value of a global variable
binary parse_hex_string(string hexstr)
Parses a hex-encoded string and returns the binary object.
nothing functionType()
This function variant does nothing at all; it is only included for backwards-compatibility with qore ...
string decode_uri_request(string uri)
Decodes percent-encoded codes in a URI path and converts "+" signs in the query component to spaces a...
const QURL_KEEP_BRACKETS
If the hostname or address is enclosed in square brackets, the brackets will be included in the "host...
Definition ql_misc.dox.h:2379
const QURL_MAINTAIN_CASE
Do not convert the protocol (scheme) to lower case when parsing URLs.
Definition ql_misc.dox.h:2383
const QURL_DECODE
Perform percent decoding on the "host", "username", and "password" fields.
Definition ql_misc.dox.h:2372
const QURL_DECODE_PATH
Decodes all fields like QURL_DECODE plus also performs percent decoding on "path" and "query" fields.
Definition ql_misc.dox.h:2374
const SIGUSR1
SIGUSR1.
Definition ql_misc.dox.h:2615
const SIGXRES
SIGXRES.
Definition ql_misc.dox.h:2629
const SIGALRM
SIGALRM.
Definition ql_misc.dox.h:2543
const SIGHUP
SIGHUP.
Definition ql_misc.dox.h:2561
const SIGTTOU
SIGTTOU.
Definition ql_misc.dox.h:2611
const SIGLWP
SIGLWP.
Definition ql_misc.dox.h:2581
const SIGCHLD
SIGCHLD.
Definition ql_misc.dox.h:2549
const SIGSYS
SIGSYS.
Definition ql_misc.dox.h:2599
const SIGPOLL
SIGPOLL.
Definition ql_misc.dox.h:2585
const SIGABRT
SIGABRT.
Definition ql_misc.dox.h:2541
const SIGWAITING
SIGWAITING.
Definition ql_misc.dox.h:2621
const SIGVTALRM
SIGVTALRM.
Definition ql_misc.dox.h:2619
const SIGTSTP
SIGTSTP.
Definition ql_misc.dox.h:2607
const SIGXFSZ
SIGXFSZ.
Definition ql_misc.dox.h:2627
const SIGBUS
SIGBUS.
Definition ql_misc.dox.h:2545
const SIGSTKFLT
SIGSTKFLT.
Definition ql_misc.dox.h:2595
const SIGPIPE
SIGPIPE.
Definition ql_misc.dox.h:2583
const SIGPROF
SIGPROF.
Definition ql_misc.dox.h:2587
const SIGILL
SIGILL.
Definition ql_misc.dox.h:2563
const SIGCLD
SIGCLD.
Definition ql_misc.dox.h:2551
const SIGURG
SIGURG.
Definition ql_misc.dox.h:2613
const SIGTRAP
SIGTRAP.
Definition ql_misc.dox.h:2605
const SIGTHAW
SIGTHAW.
Definition ql_misc.dox.h:2603
const SIGCANCEL
SIGCANCEL.
Definition ql_misc.dox.h:2547
const SIGSTOP
SIGSTOP.
Definition ql_misc.dox.h:2597
const SIGWINCH
SIGWINCH.
Definition ql_misc.dox.h:2623
const SIGEMT
SIGEMT.
Definition ql_misc.dox.h:2555
const SIGINFO
SIGINFO.
Definition ql_misc.dox.h:2565
const SIGFPE
SIGFPE.
Definition ql_misc.dox.h:2557
const SIGLOST
SIGLOST.
Definition ql_misc.dox.h:2579
const NameToSignal
maps signal names to signal values
Definition ql_misc.dox.h:2493
const SIGKILL
SIGKILL.
Definition ql_misc.dox.h:2577
const SignalToName
maps signal numbers (as a string key) to the symbolic name for the signal
Definition ql_misc.dox.h:2631
const SIGQUIT
SIGQUIT.
Definition ql_misc.dox.h:2591
const SIGIOT
SIGIOT.
Definition ql_misc.dox.h:2571
const SIGTERM
SIGTERM.
Definition ql_misc.dox.h:2601
const SIGTTIN
SIGTTIN.
Definition ql_misc.dox.h:2609
const SIGUSR2
SIGUSR2.
Definition ql_misc.dox.h:2617
const SIGCONT
SIGCONT.
Definition ql_misc.dox.h:2553
const SIGIO
SIGIO.
Definition ql_misc.dox.h:2569
const SIGXCPU
SIGXCPU.
Definition ql_misc.dox.h:2625
const SIGSEGV
SIGSEGV.
Definition ql_misc.dox.h:2593
const SIGJVM1
SIGJVM1.
Definition ql_misc.dox.h:2573
const SIGFREEZE
SIGFREEZE.
Definition ql_misc.dox.h:2559
const SIGINT
SIGINT.
Definition ql_misc.dox.h:2567
const SIGJVM2
SIGJVM2.
Definition ql_misc.dox.h:2575
const SIGPWR
SIGPWR.
Definition ql_misc.dox.h:2589
nothing set_signal_handler(softint signal, code f)
Sets or replaces a signal handler according to the signal number and closure or call reference (funct...
nothing remove_signal_handler(softint signal)
Removes a signal handler and returns the signal handling state to the default.
list< auto > list(...)
Returns a list of the arguments passed at the top level.
binary binary()
Always returns an empty binary object (of zero length)
const WARN_MODULES
The default warning mask for user modules.
Definition QC_Program.dox.h:2146
Qore namespace.
Definition QC_AbstractSmartLock.dox.h:2
a hash describing a parsed URL
Definition ql_misc.dox.h:7
string host
the hostname given in the URL string, if any
Definition ql_misc.dox.h:9
string path
the path given in the URL string, if present
Definition ql_misc.dox.h:13
string username
the username of the URL, if present
Definition ql_misc.dox.h:21
string password
the password given in the URL, if any
Definition ql_misc.dox.h:11
string query
the query part of the URL (i.e. text after any '?' char), if present
Definition ql_misc.dox.h:19
int port
the port number given in the URL string, if any
Definition ql_misc.dox.h:15
string protocol
the scheme or protocol of the URL, if present
Definition ql_misc.dox.h:17