VLCB SDK
An opinionated SDK for VLCB protocol
Loading...
Searching...
No Matches
interface.h File Reference
#include <stddef.h>
Include dependency graph for interface.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define _INTERFACE_DECLARE(T, ...)
 
#define _INTERFACE_METHOD_DECLARE(retT, name, ...)
 
#define _INTERFACE_SELF(T)
 
#define _INTERFACE_SELF_MUT(T)
 
#define _INTERFACE_SELF_PTR(T)
 
#define _INTERFACE_SELF_PTR_MUT(T)
 
#define _INTERFACE_IMPLEMENT(T)
 
#define _INTERFACE_VTABLE_DEFINE(T, ...)
 
#define _INTERFACE_VTABLE_METHOD(m, ptr, retT, ...)
 
#define _INTERFACE_ASSIGN_VTABLE(T)
 
#define _INTERFACE_PTR_STATIC_CALL(o, m, ...)
 
#define _INTERFACE_STATIC_CALL(o, m, ...)
 
#define _INTERFACE_PTR_CALL(o, m, ...)
 
#define _INTERFACE_CALL(o, m, ...)
 

Macro Definition Documentation

◆ _INTERFACE_ASSIGN_VTABLE

#define _INTERFACE_ASSIGN_VTABLE ( T)
Value:
._iface = iface##T

Definition at line 24 of file interface.h.

◆ _INTERFACE_CALL

#define _INTERFACE_CALL ( o,
m,
... )
Value:
o.m(&o, ##__VA_ARGS__)

Definition at line 29 of file interface.h.

◆ _INTERFACE_DECLARE

#define _INTERFACE_DECLARE ( T,
... )
Value:
typedef struct T { \
__VA_ARGS__ \
} T

Definition at line 5 of file interface.h.

◆ _INTERFACE_IMPLEMENT

#define _INTERFACE_IMPLEMENT ( T)
Value:
T _iface

Definition at line 18 of file interface.h.

◆ _INTERFACE_METHOD_DECLARE

#define _INTERFACE_METHOD_DECLARE ( retT,
name,
... )
Value:
retT (*const name)(__VA_ARGS__)

Definition at line 10 of file interface.h.

◆ _INTERFACE_PTR_CALL

#define _INTERFACE_PTR_CALL ( o,
m,
... )
Value:
o->m(o, ##__VA_ARGS__)

Definition at line 28 of file interface.h.

◆ _INTERFACE_PTR_STATIC_CALL

#define _INTERFACE_PTR_STATIC_CALL ( o,
m,
... )
Value:
o->m(__VA_ARGS__)

Definition at line 26 of file interface.h.

◆ _INTERFACE_SELF

#define _INTERFACE_SELF ( T)
Value:
const struct T self

Definition at line 13 of file interface.h.

◆ _INTERFACE_SELF_MUT

#define _INTERFACE_SELF_MUT ( T)
Value:
struct T

Definition at line 14 of file interface.h.

◆ _INTERFACE_SELF_PTR

#define _INTERFACE_SELF_PTR ( T)
Value:
const struct T *const self

Definition at line 15 of file interface.h.

◆ _INTERFACE_SELF_PTR_MUT

#define _INTERFACE_SELF_PTR_MUT ( T)
Value:
struct T *const self

Definition at line 16 of file interface.h.

◆ _INTERFACE_STATIC_CALL

#define _INTERFACE_STATIC_CALL ( o,
m,
... )
Value:
o.m(__VA_ARGS__)

Definition at line 27 of file interface.h.

◆ _INTERFACE_VTABLE_DEFINE

#define _INTERFACE_VTABLE_DEFINE ( T,
... )
Value:
static T iface##T = {__VA_ARGS__}

Definition at line 20 of file interface.h.

◆ _INTERFACE_VTABLE_METHOD

#define _INTERFACE_VTABLE_METHOD ( m,
ptr,
retT,
... )
Value:
.m = (retT(*const)(__VA_ARGS__))(ptr)

Definition at line 21 of file interface.h.