Files
aqhomecontrol/apps/aqhome-nodes/aqhomed.h

47 lines
1.3 KiB
C

/****************************************************************************
* This file is part of the project AqHome.
* AqHome (c) by 2023 Martin Preuss, all rights reserved.
*
* The license for this file can be found in the file COPYING which you
* should have received along with this file.
****************************************************************************/
#ifndef AQHOMED_H
#define AQHOMED_H
#include <gwenhywfar/endpoint.h>
#include <gwenhywfar/db.h>
#define AQHOME_ENDPOINTGROUP_NODE 1
#define AQHOME_ENDPOINTGROUP_IPC 2
#define AQHOME_ENDPOINTGROUP_MQTT 4
typedef struct AQHOMED AQHOMED;
AQHOMED *AqHomed_new(void);
void AqHomed_free(AQHOMED *aqh);
GWEN_MSG_ENDPOINT *AqHomed_GetTtyEndpoint(const AQHOMED *aqh);
GWEN_MSG_ENDPOINT *AqHomed_GetIpcdEndpoint(const AQHOMED *aqh);
GWEN_MSG_ENDPOINT *AqHomed_GetBrokerEndpoint(const AQHOMED *aqh);
GWEN_DB_NODE *AqHomed_GetDbArgs(const AQHOMED *aqh);
const char *AqHomed_GetLogFile(const AQHOMED *aqh);
void AqHomed_SetLogFile(AQHOMED *aqh, const char *s);
const char *AqHomed_GetPidFile(const AQHOMED *aqh);
void AqHomed_SetPidFile(AQHOMED *aqh, const char *s);
const char *AqHomed_GetDbFile(const AQHOMED *aqh);
void AqHomed_SetDbFile(AQHOMED *aqh, const char *s);
int AqHomed_GetTimeout(const AQHOMED *aqh);
#endif