GATE
gateservices.h File Reference

GATE service host implementation. More...

#include "gate/tech/microservices.h"
#include "gate/structs.h"
#include "gate/streams.h"

Classes

struct  gate_servicehost_config_service_class
 
struct  gate_servicehost_config_class
 

Macros

#define GATE_INTERFACE_NAME_GATESERVICEHOST   GATE_INTERFACE_NAME_MICROHOST GATE_INTERFACE_NAME_SEPARATOR "gateservicehost"
 
#define GATE_SERVICEHOST_CONFIG_AUTOSTART   1 /* BOOL: service is automatically started with host startup */
 
#define GATE_SERVICEHOST_CONFIG_STARTORDER   2 /* UINT32: start priority (lower means earlier) */
 
#define GATE_SERVICEHOST_CONFIG_SERVICEGROUP   3 /* STRING: service isolation group */
 
#define gate_servicehost_publish_message   gate_microhost_publish_message
 
#define gate_servicehost_publish_object   gate_microhost_publish_object
 
#define gate_servicehost_subscribe_messages   gate_microhost_subscribe_messages
 
#define gate_servicehost_unsubscribe_messages   gate_microhost_unsubscribe_messages
 
#define gate_servicehost_subscribe_objects   gate_microhost_subscribe_objects
 
#define gate_servicehost_unsubscribe_objects   gate_microhost_unsubscribe_objects
 
#define gate_servicehost_remote_invoke   gate_microhost_remote_invoke
 
#define gate_servicehost_log   gate_microhost_log
 
#define gate_servicehost_add_factory(host, factory, factory_name)    ((gate_servicehost_t*)(host))->vtbl->add_factory((host), (factory), (factory_name))
 
#define gate_servicehost_remove_factory(host, factory_name)    ((gate_servicehost_t*)(host))->vtbl->remove_factory((host), (factory_name))
 
#define gate_servicehost_get_factory_service_names(host, names)    ((gate_servicehost_t*)(host))->vtbl->get_factory_service_names((host), (names))
 
#define gate_servicehost_create_service(host, service_name, service_instance, service_address)    ((gate_servicehost_t*)(host))->vtbl->create_service((host), (service_name), (service_instance), (service_address))
 
#define gate_servicehost_get_service_addresses(host, addresses)    ((gate_servicehost_t*)(host))->vtbl->get_service_addresses((host), (addresses))
 
#define gate_servicehost_get_service(host, service_address, ptr_service)    ((gate_servicehost_t*)(host))->vtbl->get_service((host), (service_address), (ptr_service))
 
#define gate_servicehost_get_service_config(host, service_address, config_type, ptr_value)    ((gate_servicehost_t*)(host))->vtbl->get_service_config((host), (service_address), (config_type), ptr_value)
 
#define gate_servicehost_set_service_config(host, service_address, config_type, ptr_value)    ((gate_servicehost_t*)(host))->vtbl->set_service_config((host), (service_address), (config_type), (ptr_value))
 
#define gate_servicehost_start_service(host, service_address)    ((gate_servicehost_t*)(host))->vtbl->start_service((host), (service_address))
 
#define gate_servicehost_stop_service(host, service_address)    ((gate_servicehost_t*)(host))->vtbl->stop_service((host), (service_address))
 
#define gate_servicehost_release_service(host, service_address)    ((gate_servicehost_t*)(host))->vtbl->release_service((host), (service_address))
 
#define gate_servicehost_startup(host)    ((gate_servicehost_t*)(host))->vtbl->startup((host))
 
#define gate_servicehost_shutdown(host)    ((gate_servicehost_t*)(host))->vtbl->shutdown((host))
 
#define GATE_SERVICEHOST_CONFIG_FORMAT_JSON   1
 
#define GATE_SERVICEHOST_CONFIG_FORMAT_YAML   2
 

Typedefs

typedef struct gate_servicehost_config_service_class gate_servicehost_config_service_t
 
typedef struct gate_servicehost_config_class gate_servicehost_config_t
 

Functions

 GATE_INTERFACE (gate_servicehost)
 
GATE_TECH_API gate_servicehost_t * gate_servicehost_create ()
 
GATE_TECH_API gate_microfactory_t * gate_servicehost_essentials_factory ()
 
GATE_TECH_API gate_result_t gate_servicehost_config_service_copy_constructor (void *dest, void const *src)
 
GATE_TECH_API gate_result_t gate_servicehost_config_service_init (gate_struct_t *ptr)
 
GATE_TECH_API void * gate_servicehost_config_copy_constructor (void *dest, void const *src)
 
GATE_TECH_API gate_result_t gate_servicehost_config_init (gate_struct_t *ptr)
 
GATE_TECH_API gate_result_t gate_servicehost_load_config (gate_stream_t *srcstream, gate_uint32_t format, gate_servicehost_config_t *ptr_config)
 
GATE_TECH_API gate_result_t gate_servicehost_save_config (gate_servicehost_config_t const *config, gate_uint32_t format, gate_stream_t *deststream)
 
GATE_TECH_API gate_result_t gate_servicehost_import_config (gate_servicehost_t *host, gate_servicehost_config_t const *config)
 
GATE_TECH_API gate_result_t gate_servicehost_export_config (gate_servicehost_t *host, gate_servicehost_config_t *config)
 
GATE_TECH_API gate_result_t gate_servicehost_release_services (gate_servicehost_t *host)
 

Detailed Description

GATE service host implementation.