LibJuno 0.23.0
LibJuno is a lightweight C99 library designed specifically for embedded systems.
Loading...
Searching...
No Matches
publisher_api.h
Go to the documentation of this file.
1/*
2 MIT License
3
4 Copyright (c) 2025 Robin A. Onsay
5
6 Permission is hereby granted, free of charge, to any person obtaining
7 a copy of this software and associated documentation files
8 (the "Software"), to deal in the Software without restriction,
9 including without limitation the rights to use, copy, modify, merge,
10 publish, distribute, sublicense, and/or sell copies of the Software,
11 and to permit persons to whom the Software is furnished to do so,
12 subject to the following conditions:
13
14 The above copyright notice and this permission notice shall be
15 included in all copies or substantial portions of the Software.
16*/
17
27#ifndef JUNO_PUBLISHER_API_H
28#define JUNO_PUBLISHER_API_H
29#include "juno/sb/msg_api.h"
30#include "juno/status.h"
31#include "juno/module.h"
32#ifdef __cplusplus
33extern "C"
34{
35#endif
36
38typedef struct JUNO_PUBLISHER_ID_TAG JUNO_PUBLISHER_ID_T;
39
40JUNO_MODULE_DECLARE(JUNO_PUBLISHER_T);
41JUNO_MODULE_BASE_DECLARE(JUNO_PUBLISHER_BASE_T);
42
44 JUNO_PUBLISHER_ID_T *ptPublisherId;
45);
46
48{
50 JUNO_STATUS_T (*Publish)(JUNO_PUBLISHER_T *ptJunoPublisher, const JUNO_MSG_T *ptMsg);
52 JUNO_STATUS_T (*GetPublisherId)(JUNO_PUBLISHER_T *ptJunoPublisher, JUNO_PUBLISHER_ID_T *ptRetPublisherId);
53};
54
55#ifdef __cplusplus
56}
57#endif
58#endif // JUNO_PUBLISHER_API_H
#define JUNO_MODULE_BASE(name, API, members)
Definition module.h:81
#define JUNO_MODULE_BASE_DECLARE(name)
Definition module.h:31
#define JUNO_MODULE_DECLARE(name)
Definition module.h:26
struct JUNO_PUBLISHER_ID_TAG JUNO_PUBLISHER_ID_T
Definition publisher_api.h:38
enum JUNO_STATUS_TAG JUNO_STATUS_T
Definition publisher_api.h:48
JUNO_STATUS_T(* Publish)(JUNO_PUBLISHER_T *ptJunoPublisher, const JUNO_MSG_T *ptMsg)
Publish a sb messaage.
Definition publisher_api.h:50
JUNO_STATUS_T(* GetPublisherId)(JUNO_PUBLISHER_T *ptJunoPublisher, JUNO_PUBLISHER_ID_T *ptRetPublisherId)
Get the publisher ID.
Definition publisher_api.h:52