plugin-common

Name

plugin-common -- 

Synopsis



#define     PLUGIN_GENERIC
typedef     plugin_generic_t;
#define     plugin_name                     (p)
#define     plugin_name_len                 (p)
#define     plugin_author                   (p)
#define     plugin_author_len               (p)
#define     plugin_contact                  (p)
#define     plugin_contact_len              (p)
#define     plugin_desc                     (p)
#define     plugin_desc_len                 (p)
#define     plugin_set_name                 (p, str)
#define     plugin_set_author               (p, str)
#define     plugin_set_contact              (p, str)
#define     plugin_set_desc                 (p, str)
int         plugin_subscribe                (plugin_generic_t *plugin);
int         plugin_unsubscribe              (plugin_generic_t *plugin);
int         plugin_request_new_id           (void);

Description

Details

PLUGIN_GENERIC

#define     PLUGIN_GENERIC


plugin_generic_t

typedef struct {
        PLUGIN_GENERIC;
} plugin_generic_t;


plugin_name()

#define plugin_name(p) (p)->name

p :


plugin_name_len()

#define plugin_name_len(p) (p)->namelen

p :


plugin_author()

#define plugin_author(p) (p)->author

p :


plugin_author_len()

#define plugin_author_len(p) (p)->authorlen

p :


plugin_contact()

#define plugin_contact(p) (p)->contact

p :


plugin_contact_len()

#define plugin_contact_len(p) (p)->contactlen

p :


plugin_desc()

#define plugin_desc(p) (p)->desc

p :


plugin_desc_len()

#define plugin_desc_len(p) (p)->desclen

p :


plugin_set_name()

#define     plugin_set_name(p, str)

p :

str :


plugin_set_author()

#define     plugin_set_author(p, str)

p :

str :


plugin_set_contact()

#define     plugin_set_contact(p, str)

p :

str :


plugin_set_desc()

#define     plugin_set_desc(p, str)

p :

str :


plugin_subscribe ()

int         plugin_subscribe                (plugin_generic_t *plugin);

Set plugin to be active.

The subscribe function specified in plugin_load_from_dir() is called for plugin registration.

plugin :

Pointer to a plugin.

Returns :

0 on success or -1 if an error occured.


plugin_unsubscribe ()

int         plugin_unsubscribe              (plugin_generic_t *plugin);

Set plugin to be inactive.

The unsubscribe function specified in plugin_load_from_dir() is called for plugin un-registration.

plugin :

Pointer to a plugin.

Returns :

0 on success, -1 if an error occured.


plugin_request_new_id ()

int         plugin_request_new_id           (void);

Returns :