Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Globals | Related Pages

imaphandler.h File Reference


Detailed Description

Derived from tcptxthandler. Attempts to connect() and then does a protocol specific service check.

If no port is provided in URL, the standard port is used.

Wire keywords (standard handler keywords documented in Wire )

Example:
set noconnect create event { name: "noconnect" priority: 1 } set noservice create event { name: "noservice" priority: 1 }

create handler imap { url: imap://mail.mydomain.com noconnect: $noconnect noservice: $noservice timeout: 5 cycletime: 60 }

Events generated:
Event NameTypeDescription
connect AW_EVENT_TYPE_STRING Was able to connect, send string of "url"
noconnect AW_EVENT_TYPE_STRING Was NOT able to connect, send string of "url"
service AW_EVENT_TYPE_STRING service check successful, send string of "url"
noservice AW_EVENT_TYPE_STRING service check UNsuccessful, send string of "url"

#include "tcptxthandler.h"

Go to the source code of this file.

Typedefs

typedef aw_tcptxthandler_events_t aw_imaphandler_events_t
typedef aw_tcptxthandler_t aw_imaphandler_t

Functions

aw_imaphandler_t * aw_create_imaphandler (const aw_imaphandler_events_t *events, const byte_t *url, const aw_timestamp_t timeout, int32_t(*regevent)(aw_handler_t *h, aw_address_t *eventid, u_int32_t index), int32_t(*regmaskevent)(aw_handler_t *h, aw_address_t *eventid, u_int32_t index), const aw_alarm_sched_t *sched, aw_logger_t *logger)
 Create a imap handler.

void aw_free_imaphandler (aw_imaphandler_t *p)
 Free handler and all associated resources.

aw_handler_t * aw_wire_imaphandler (aw_wire_mkhandler_args_t *args)
 Create a imap handler using "wire". See header doc for keyword documentation.


Typedef Documentation

typedef aw_tcptxthandler_events_t aw_imaphandler_events_t
 

typedef aw_tcptxthandler_t aw_imaphandler_t
 


Function Documentation

aw_imaphandler_t* aw_create_imaphandler (  const aw_imaphandler_events_t *  events,
const byte_t *  url,
const aw_timestamp_t  timeout,
int32_t(*  regevent)(aw_handler_t *h, aw_address_t *eventid, u_int32_t index),
int32_t(*  regmaskevent)(aw_handler_t *h, aw_address_t *eventid, u_int32_t index),
const aw_alarm_sched_t *  sched,
aw_logger_t *  logger
) 
 

Create a imap handler.

aw_create_imaphandler

Parameters:
events Events to generate
url Url (gives us host and port)
timeout Max time to run
regevent Function pointer for event registration
regmaskevent Function pointer for event mask registration
sched Run schedule
logger Logger object
Returns:
Handler object

void aw_free_imaphandler (  aw_imaphandler_t *  p  ) 
 

Free handler and all associated resources.

aw_free_imaphandler

Parameters:
p The handler

aw_handler_t* aw_wire_imaphandler (  aw_wire_mkhandler_args_t *  args  ) 
 

Create a imap handler using "wire". See header doc for keyword documentation.

aw_wire_imaphandler

Aware 0.11.1 Copyright (C) 1998-2005 Russell Leighton (russ@elegant-software.com)