|
PostgreSQL Source Code git master
|
#include "postgres.h"#include "common/hashfn.h"#include "libpq/pqformat.h"#include "port/pg_bswap.h"#include "utils/fmgrprotos.h"#include "utils/inet.h"#include "utils/sortsupport.h"
Go to the source code of this file.
Macros | |
| #define | hibits(addr) ((unsigned long)(((addr)->a<<16)|((addr)->b<<8)|((addr)->c))) |
| #define | lobits(addr) ((unsigned long)(((addr)->d<<16)|((addr)->e<<8)|((addr)->f))) |
Definition at line 28 of file mac.c.
| Datum hashmacaddr | ( | PG_FUNCTION_ARGS | ) |
| Datum hashmacaddrextended | ( | PG_FUNCTION_ARGS | ) |
Definition at line 264 of file mac.c.
References hash_any_extended(), PG_GETARG_INT64, and PG_GETARG_MACADDR_P.
|
static |
Definition at line 389 of file mac.c.
Referenced by macaddr_sortsupport().
|
static |
Definition at line 404 of file mac.c.
References DatumBigEndianToNative, DatumGetMacaddrP(), fb(), memcpy(), and StaticAssertDecl.
Referenced by macaddr_sortsupport().
| Datum macaddr_and | ( | PG_FUNCTION_ARGS | ) |
Definition at line 292 of file mac.c.
References fb(), palloc_object, PG_GETARG_MACADDR_P, PG_RETURN_MACADDR_P, and result.
| Datum macaddr_cmp | ( | PG_FUNCTION_ARGS | ) |
Definition at line 186 of file mac.c.
References a1, a2, macaddr_cmp_internal(), PG_GETARG_MACADDR_P, and PG_RETURN_INT32.
Referenced by gbt_macaddr_ssup_cmp(), and gbt_macadkey_cmp().
Definition at line 171 of file mac.c.
References a1, a2, hibits, and lobits.
Referenced by macaddr_cmp(), macaddr_eq(), macaddr_fast_cmp(), macaddr_ge(), macaddr_gt(), macaddr_le(), macaddr_lt(), and macaddr_ne().
| Datum macaddr_eq | ( | PG_FUNCTION_ARGS | ) |
Definition at line 217 of file mac.c.
References a1, a2, macaddr_cmp_internal(), PG_GETARG_MACADDR_P, and PG_RETURN_BOOL.
Referenced by gbt_macadeq().
|
static |
Definition at line 375 of file mac.c.
References DatumGetMacaddrP(), fb(), macaddr_cmp_internal(), x, and y.
Referenced by macaddr_sortsupport().
| Datum macaddr_ge | ( | PG_FUNCTION_ARGS | ) |
Definition at line 226 of file mac.c.
References a1, a2, macaddr_cmp_internal(), PG_GETARG_MACADDR_P, and PG_RETURN_BOOL.
Referenced by gbt_macadge().
| Datum macaddr_gt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 235 of file mac.c.
References a1, a2, macaddr_cmp_internal(), PG_GETARG_MACADDR_P, and PG_RETURN_BOOL.
Referenced by gbt_macadgt().
| Datum macaddr_in | ( | PG_FUNCTION_ARGS | ) |
Definition at line 44 of file mac.c.
References a, b, ereturn, errcode(), errmsg, fb(), palloc_object, PG_GETARG_CSTRING, PG_RETURN_MACADDR_P, result, and str.
| Datum macaddr_le | ( | PG_FUNCTION_ARGS | ) |
Definition at line 208 of file mac.c.
References a1, a2, macaddr_cmp_internal(), PG_GETARG_MACADDR_P, and PG_RETURN_BOOL.
Referenced by gbt_macadle().
| Datum macaddr_lt | ( | PG_FUNCTION_ARGS | ) |
Definition at line 199 of file mac.c.
References a1, a2, macaddr_cmp_internal(), PG_GETARG_MACADDR_P, and PG_RETURN_BOOL.
Referenced by gbt_macadlt().
| Datum macaddr_ne | ( | PG_FUNCTION_ARGS | ) |
Definition at line 244 of file mac.c.
References a1, a2, macaddr_cmp_internal(), PG_GETARG_MACADDR_P, and PG_RETURN_BOOL.
| Datum macaddr_not | ( | PG_FUNCTION_ARGS | ) |
Definition at line 276 of file mac.c.
References fb(), palloc_object, PG_GETARG_MACADDR_P, PG_RETURN_MACADDR_P, and result.
| Datum macaddr_or | ( | PG_FUNCTION_ARGS | ) |
Definition at line 309 of file mac.c.
References fb(), palloc_object, PG_GETARG_MACADDR_P, PG_RETURN_MACADDR_P, and result.
| Datum macaddr_out | ( | PG_FUNCTION_ARGS | ) |
Definition at line 110 of file mac.c.
References macaddr::a, macaddr::b, macaddr::c, macaddr::d, macaddr::e, macaddr::f, palloc(), PG_GETARG_MACADDR_P, PG_RETURN_CSTRING, result, and snprintf.
| Datum macaddr_recv | ( | PG_FUNCTION_ARGS | ) |
Definition at line 129 of file mac.c.
References macaddr::a, macaddr::b, buf, macaddr::c, macaddr::d, macaddr::e, macaddr::f, palloc_object, PG_GETARG_POINTER, PG_RETURN_MACADDR_P, and pq_getmsgbyte().
| Datum macaddr_send | ( | PG_FUNCTION_ARGS | ) |
Definition at line 150 of file mac.c.
References macaddr::a, macaddr::b, buf, macaddr::c, macaddr::d, macaddr::e, macaddr::f, PG_GETARG_MACADDR_P, PG_RETURN_BYTEA_P, pq_begintypsend(), pq_endtypsend(), and pq_sendbyte().
| Datum macaddr_sortsupport | ( | PG_FUNCTION_ARGS | ) |
Definition at line 352 of file mac.c.
References SortSupportData::abbrev_abort, SortSupportData::abbrev_converter, SortSupportData::abbrev_full_comparator, SortSupportData::abbreviate, SortSupportData::comparator, fb(), macaddr_abbrev_abort(), macaddr_abbrev_convert(), macaddr_fast_cmp(), PG_GETARG_POINTER, PG_RETURN_VOID, ssup_datum_unsigned_cmp(), and SortSupportData::ssup_extra.
| Datum macaddr_trunc | ( | PG_FUNCTION_ARGS | ) |
Definition at line 330 of file mac.c.
References macaddr::a, macaddr::b, macaddr::c, palloc_object, PG_GETARG_MACADDR_P, PG_RETURN_MACADDR_P, and result.