Desktop

/* $Id: modem.h,v 1.27.2.3 2011/01/22 15:38:00 khorben Exp $ */
/* Copyright (c) 2011 Pierre Pronchery <khorben@defora.org> */
/* This file is part of DeforaOS Desktop Phone */
/* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, version 3 of the License.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifndef PHONE_MODEM_H
# define PHONE_MODEM_H
# include "Phone/modem.h"
/* Modem */
/* public */
/* types */
typedef void (*ModemEventCallback)(void * priv, ModemEvent * event);
/* functions */
Modem * modem_new(char const * plugin, ModemEventCallback callback,
void * priv);
void modem_delete(Modem * modem);
/* accessors */
void modem_set_callback(Modem * modem, ModemEventCallback callback,
void * priv);
/* useful */
int modem_request(Modem * modem, ModemRequest * request);
int modem_request_type(Modem * modem, ModemRequestType type, ...);
int modem_start(Modem * modem);
int modem_stop(Modem * modem);
int modem_trigger(Modem * modem, ModemEventType event);
#endif /* !PHONE_MODEM_H */