Logo Search packages:      
Sourcecode: mail-notification version File versions

mn-message.h

/* Generated by GOB (v2.0.11)   (do not edit directly) */

#include <glib.h>
#include <glib-object.h>


#include <time.h>
#include "mn-uri.h"

#ifndef __MN_MESSAGE_H__
#define __MN_MESSAGE_H__

#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */


/*
 * Type checking and casting macros
 */
#define MN_TYPE_MESSAGE (mn_message_get_type())
#define MN_MESSAGE(obj) G_TYPE_CHECK_INSTANCE_CAST((obj), mn_message_get_type(), MNMessage)
#define MN_MESSAGE_CONST(obj) G_TYPE_CHECK_INSTANCE_CAST((obj), mn_message_get_type(), MNMessage const)
#define MN_MESSAGE_CLASS(klass)     G_TYPE_CHECK_CLASS_CAST((klass), mn_message_get_type(), MNMessageClass)
#define MN_IS_MESSAGE(obj)    G_TYPE_CHECK_INSTANCE_TYPE((obj), mn_message_get_type ())

#define MN_MESSAGE_GET_CLASS(obj)   G_TYPE_INSTANCE_GET_CLASS((obj), mn_message_get_type(), MNMessageClass)

/*
 * Main object structure
 */
#ifndef __TYPEDEF_MN_MESSAGE__
#define __TYPEDEF_MN_MESSAGE__
typedef struct _MNMessage MNMessage;
#endif
struct _MNMessage {
      GObject __parent__;
      /*< public >*/
      MNURI * mailbox_uri;
      char * error;
      time_t sent_time;
      char * id;
      char * from;
      char * subject;
};

/*
 * Class definition
 */
typedef struct _MNMessageClass MNMessageClass;
struct _MNMessageClass {
      GObjectClass __parent__;
};


/*
 * Public methods
 */
GType mn_message_get_type     (void);
char *      mn_message_format_sent_time   (MNMessage * self);
MNMessage *       mn_message_new    (MNURI * mailbox_uri,
                              const char * error,
                              time_t sent_time,
                              const char * id,
                              const char * from,
                              const char * subject);
MNMessage *       mn_message_new_from_error     (MNURI * mailbox_uri,
                              const char * error);
GSList *    mn_message_slist_find_by_id   (GSList * list,
                              MNMessage * self);
GSList *    mn_message_slist_sort_by_sent_time  (GSList * list);

/*
 * Argument wrapping macros
 */
#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
#define MN_MESSAGE_PROP_MAILBOX_URI(arg)        "mailbox_uri", __extension__ ({GObject *z = (arg); z;})
#define MN_MESSAGE_GET_PROP_MAILBOX_URI(arg)    "mailbox_uri", __extension__ ({GObject **z = (arg); z;})
#define MN_MESSAGE_PROP_ERROR(arg)        "error", __extension__ ({gchar *z = (arg); z;})
#define MN_MESSAGE_GET_PROP_ERROR(arg)    "error", __extension__ ({gchar **z = (arg); z;})
#define MN_MESSAGE_PROP_SENT_TIME(arg)          "sent_time", __extension__ ({gulong z = (arg); z;})
#define MN_MESSAGE_GET_PROP_SENT_TIME(arg)      "sent_time", __extension__ ({gulong *z = (arg); z;})
#define MN_MESSAGE_PROP_ID(arg)     "id", __extension__ ({gchar *z = (arg); z;})
#define MN_MESSAGE_GET_PROP_ID(arg) "id", __extension__ ({gchar **z = (arg); z;})
#define MN_MESSAGE_PROP_FROM(arg)         "from", __extension__ ({gchar *z = (arg); z;})
#define MN_MESSAGE_GET_PROP_FROM(arg)     "from", __extension__ ({gchar **z = (arg); z;})
#define MN_MESSAGE_PROP_SUBJECT(arg)      "subject", __extension__ ({gchar *z = (arg); z;})
#define MN_MESSAGE_GET_PROP_SUBJECT(arg)  "subject", __extension__ ({gchar **z = (arg); z;})
#else /* __GNUC__ && !__STRICT_ANSI__ */
#define MN_MESSAGE_PROP_MAILBOX_URI(arg)        "mailbox_uri",(GObject *)(arg)
#define MN_MESSAGE_GET_PROP_MAILBOX_URI(arg)    "mailbox_uri",(GObject **)(arg)
#define MN_MESSAGE_PROP_ERROR(arg)        "error",(gchar *)(arg)
#define MN_MESSAGE_GET_PROP_ERROR(arg)    "error",(gchar **)(arg)
#define MN_MESSAGE_PROP_SENT_TIME(arg)          "sent_time",(gulong )(arg)
#define MN_MESSAGE_GET_PROP_SENT_TIME(arg)      "sent_time",(gulong *)(arg)
#define MN_MESSAGE_PROP_ID(arg)     "id",(gchar *)(arg)
#define MN_MESSAGE_GET_PROP_ID(arg) "id",(gchar **)(arg)
#define MN_MESSAGE_PROP_FROM(arg)         "from",(gchar *)(arg)
#define MN_MESSAGE_GET_PROP_FROM(arg)     "from",(gchar **)(arg)
#define MN_MESSAGE_PROP_SUBJECT(arg)      "subject",(gchar *)(arg)
#define MN_MESSAGE_GET_PROP_SUBJECT(arg)  "subject",(gchar **)(arg)
#endif /* __GNUC__ && !__STRICT_ANSI__ */


#ifdef __cplusplus
}
#endif /* __cplusplus */

#endif

Generated by  Doxygen 1.6.0   Back to index