File porting.h¶
Go to the source code of this file
#include "config.h"#include <type_traits>#include <utility>
Public Types¶
| Type | Name |
|---|---|
| typedef void(* | SIGNAL_HANDLER_FUNCTION |
| typedef int | SOCKET |
Public Functions¶
Macros¶
| Type | Name |
|---|---|
| define | CAST_BUFLEN ([**int**](broker__monitor_8c.md#function-timeout)) |
| define | CAST_STRLEN ([**int**](broker__monitor_8c.md#function-timeout)) |
| define | CONST_CAST (dest_type, expr) [**const\_cast**](broker__monitor_8c.md#function-timeout)<[**dest\_type**](broker__monitor_8c.md#function-timeout)>(expr) |
| define | COPYMEM (type, dst, src) /* multi line expression */ |
| define | CTIME_MAX 64 |
| define | CUB_MAXHOSTNAMELEN 256 /\* 255 + 1([**for**](dynamic__load_8c.md#function-for) [**NULL**](freelistheap_8h.md#define-null) [**terminator**](broker__monitor_8c.md#function-timeout)) \*/ |
| define | DYNAMIC_CAST (dest_type, expr) [**dynamic\_cast**](broker__monitor_8c.md#function-timeout)<[**dest\_type**](broker__monitor_8c.md#function-timeout)>(expr) |
| define | EXPORT_IMPORT |
| define | FINITE (x) [**finite**](broker__monitor_8c.md#function-timeout)([**x**](broker__monitor_8c.md#function-timeout)) |
| define | GETHOSTNAME (p, l) [**css\_gethostname**](tcp_8c.md#function-css_gethostname)([**p**](dynamic__load_8c.md#variable-p), l) |
| define | INVALID_SOCKET (-1) |
| define | IS_ABS_PATH (p) [**IS\_PATH\_SEPARATOR**](porting_8h.md#define-is_path_separator)(([**p**](dynamic__load_8c.md#variable-p))[0]) |
| define | IS_INVALID_SOCKET (socket) (([**socket**](broker__monitor_8c.md#function-timeout)) < 0) |
| define | IS_PATH_SEPARATOR (c) ((c) == [**PATH\_SEPARATOR**](porting_8h.md#define-path_separator)) |
| define | LLONG_MAX 9223372036854775807[**LL**](broker__monitor_8c.md#function-timeout) |
| define | LLONG_MIN (-[**LLONG\_MAX**](porting_8h.md#define-llong_max) - 1[**LL**](broker__monitor_8c.md#function-timeout)) |
| define | LONGJMP [**\_longjmp**](broker__monitor_8c.md#function-timeout) |
| define | L_cuserid 9 |
| define | MEM_SIZE_IS_VALID (size) /* multi line expression */ |
| define | OFF_T_MAX [**LLONG\_MAX**](porting_8h.md#define-llong_max) |
| define | ONE_G 1073741824 |
| define | ONE_HOUR 3600000 |
| define | ONE_K 1024 |
| define | ONE_M 1048576 |
| define | ONE_MIN 60000 |
| define | ONE_P 1125899906842624[**LL**](broker__monitor_8c.md#function-timeout) |
| define | ONE_SEC 1000 |
| define | ONE_T 1099511627776[**LL**](broker__monitor_8c.md#function-timeout) |
| define | PATH_CURRENT '.' |
| define | PATH_SEPARATOR '/' |
| define | PORTABLE_FUNC_NAME [**\_\_func\_\_**](broker__monitor_8c.md#function-timeout) |
| define | PREFETCH_CACHE_L1 3 |
| define | PREFETCH_CACHE_L2 2 |
| define | PREFETCH_CACHE_L3 1 |
| define | PREFETCH_CACHE_NEVER 0 |
| define | PREFETCH_READ 0 |
| define | PREFETCH_WRITE 1 |
| define | REFPTR (T, name) T \*& name |
| define | REINTERPRET_CAST (dest_type, expr) [**reinterpret\_cast**](broker__monitor_8c.md#function-timeout)<[**dest\_type**](broker__monitor_8c.md#function-timeout)>(expr) |
| define | SETJMP [**\_setjmp**](broker__monitor_8c.md#function-timeout) |
| define | STATIC_CAST (dest_type, expr) [**static\_cast**](broker__monitor_8c.md#function-timeout)<[**dest\_type**](broker__monitor_8c.md#function-timeout)>(expr) |
| define | SUPPRESS_STRLEN_WARNING |
| define | THREAD_CALLING_CONVENTION |
| define | THREAD_RET_T [**void**](broker__monitor_8c.md#function-timeout)\* |
| define | ULLONG_MAX 18446744073709551615[**ULL**](broker__monitor_8c.md#function-timeout) |
| define | UNUSED (x) [**UNUSED\_**](broker__monitor_8c.md#function-timeout) ## [**x**](broker__monitor_8c.md#function-timeout) [**\_\_attribute\_\_**](broker__monitor_8c.md#function-timeout)(([**\_\_unused\_\_**](broker__monitor_8c.md#function-timeout))) |
| define | UNUSED_FUNCTION (x) [**\_\_attribute\_\_**](broker__monitor_8c.md#function-timeout)(([**\_\_unused\_\_**](broker__monitor_8c.md#function-timeout))) [**UNUSED\_**](broker__monitor_8c.md#function-timeout) ## [**x**](broker__monitor_8c.md#function-timeout) |
| define | difftime64 (time1, time2) [**difftime**](broker__monitor_8c.md#function-timeout)([**time1**](broker__monitor_8c.md#function-timeout), [**time2**](broker__monitor_8c.md#function-timeout)) |
| define | err (fd, ...) [**do**](dynamic__load_8c.md#variable-do) { [**fprintf**](broker__monitor_8c.md#function-timeout)([**stderr**](broker__monitor_8c.md#function-timeout), [**\_\_VA\_ARGS\_\_**](broker__monitor_8c.md#function-timeout)); [**exit**](broker__monitor_8c.md#function-timeout)(1); } [**while**](dynamic__load_8c.md#function-while) (0) |
| define | errx (fd, ...) [**do**](dynamic__load_8c.md#variable-do) { [**fprintf**](broker__monitor_8c.md#function-timeout)([**stderr**](broker__monitor_8c.md#function-timeout), [**\_\_VA\_ARGS\_\_**](broker__monitor_8c.md#function-timeout)); [**exit**](broker__monitor_8c.md#function-timeout)(1); } [**while**](dynamic__load_8c.md#function-while) (0) |
| define | likely (x) [**\_\_builtin\_expect**](broker__monitor_8c.md#function-timeout)(!!([**x**](broker__monitor_8c.md#function-timeout)), 1) |
| define | os_send_kill () [**os\_send\_signal**](porting_8c.md#function-os_send_signal)([**SIGKILL**](broker__monitor_8c.md#function-timeout)) |
| define | prefetch (x, y, z) [**\_\_builtin\_prefetch**](broker__monitor_8c.md#function-timeout)(([**x**](broker__monitor_8c.md#function-timeout)), ([**y**](broker__monitor_8c.md#function-timeout)), ([**z**](broker__monitor_8c.md#function-timeout))) |
| define | snprintf_dots_truncate (dest, max_len, ...) /* multi line expression */ |
| define | string_to_double (str, end_ptr) [**strtod**](broker__monitor_8c.md#function-timeout)((str), ([**end\_ptr**](broker__monitor_8c.md#function-timeout))) |
| define | strncpy_bufsize (buf, str) [**strncpy\_size**](porting_8h.md#define-strncpy_size) (buf, str, [**sizeof**](broker__monitor_8c.md#function-timeout) (buf)); [**check\_is\_array**](porting_8h.md#function-check_is_array) (buf) |
| define | strncpy_size (buf, str, size) [**strncpy**](broker__monitor_8c.md#function-timeout) (buf, str, size); buf[(size) - 1] = '\0' |
| define | unlikely (x) [**\_\_builtin\_expect**](broker__monitor_8c.md#function-timeout)(!!([**x**](broker__monitor_8c.md#function-timeout)), 0) |
Public Types Documentation¶
typedef SIGNAL_HANDLER_FUNCTION¶
typedef SOCKET¶
Public Functions Documentation¶
function asprintf¶
function basename¶
function basename_r¶
function check_is_array¶
function cub_dirname_r¶
function dirname¶
function getuserid¶
function itona¶
function msleep¶
function os_rename_file¶
function os_send_signal¶
function os_set_signal_handler¶
SIGNAL_HANDLER_FUNCTION os_set_signal_handler (
const int sig_no,
SIGNAL_HANDLER_FUNCTION sig_handler
)
function parse_bigint¶
function parse_int¶
function port_close_memstream¶
function port_open_memstream¶
function str_to_double¶
function str_to_float¶
function str_to_int32¶
function str_to_int64¶
function str_to_uint32¶
function str_to_uint64¶
function strdup¶
function stristr¶
function strlcpy¶
function timeval_add_msec¶
function timeval_diff_in_msec¶
function timeval_to_timespec¶
function utona¶
function vasprintf¶
Macro Definition Documentation¶
define CAST_BUFLEN¶
define CAST_STRLEN¶
define CONST_CAST¶
define COPYMEM¶
define CTIME_MAX¶
define CUB_MAXHOSTNAMELEN¶
RFC1123 - Section 2.1 https://tools.ietf.org/html/rfc1123
Host software MUST handle host names of up to 63 characters and SHOULD handle host names of up to 255 characters.
define DYNAMIC_CAST¶
define EXPORT_IMPORT¶
define FINITE¶
define GETHOSTNAME¶
define INVALID_SOCKET¶
define IS_ABS_PATH¶
define IS_INVALID_SOCKET¶
define IS_PATH_SEPARATOR¶
define LLONG_MAX¶
define LLONG_MIN¶
define LONGJMP¶
define L_cuserid¶
define MEM_SIZE_IS_VALID¶
define OFF_T_MAX¶
define ONE_G¶
define ONE_HOUR¶
define ONE_K¶
define ONE_M¶
define ONE_MIN¶
define ONE_P¶
define ONE_SEC¶
define ONE_T¶
define PATH_CURRENT¶
define PATH_SEPARATOR¶
define PORTABLE_FUNC_NAME¶
define PREFETCH_CACHE_L1¶
define PREFETCH_CACHE_L2¶
define PREFETCH_CACHE_L3¶
define PREFETCH_CACHE_NEVER¶
define PREFETCH_READ¶
define PREFETCH_WRITE¶
define REFPTR¶
define REINTERPRET_CAST¶
define SETJMP¶
define STATIC_CAST¶
define SUPPRESS_STRLEN_WARNING¶
define THREAD_CALLING_CONVENTION¶
define THREAD_RET_T¶
define ULLONG_MAX¶
define UNUSED¶
define UNUSED_FUNCTION¶
define difftime64¶
define err¶
define errx¶
define likely¶
define os_send_kill¶
define prefetch¶
define snprintf_dots_truncate¶
#define snprintf_dots_truncate (
dest,
max_len,
...
) `if ( snprintf (dest, max_len, __VA_ARGS__ ) < 0) \ snprintf (dest + max_len - 4, 4, "...")`
define string_to_double¶
define strncpy_bufsize¶
define strncpy_size¶
define unlikely¶
The documentation for this class was generated from the following file cubrid/src/base/porting.h