Wave Arts VQE  1.00
Voice Quality Enhancement
WaList.h
Go to the documentation of this file.
00001 /*
00002  * This file is part of the Wave Arts VQE library.
00003  * Copyright (C) 2011 Wave Arts, Inc. (http://wavearts.com)
00004  *
00005  * VQE is free software; you can redistribute it and/or modify
00006  * it under the terms of the GNU General Public License as published by
00007  * the Free Software Foundation; either version 2 of the License, or
00008  * (at your option) any later version.
00009  *
00010  * VQE is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  * GNU General Public License for more details.
00014  *
00015  * A copy of the GNU General Public License is included with VQE,
00016  * and can be found online at <http://www.gnu.org/licenses/>.
00017  *
00018  * If you'd like to distribute a closed-source product which uses VQE,
00019  * you must obtain a commercial VQE license from Wave Arts.
00020  */
00027 #ifndef _LIST_H
00028 #define _LIST_H
00029 
00030 /*
00031  * ITEM starts with ptr to next element, NULL if none.
00032  */
00033 typedef struct item_tag {
00034         struct item_tag *next;
00035 } ITEM;
00036 
00037 /*
00038  * LIST structure contains head and tail ptrs to ITEMs, NULL if no items.
00039  */
00040 typedef struct {
00041         ITEM    *head;
00042         ITEM    *tail;
00043 } LIST;
00044 
00045 /*
00046  * An item containing a LIST, for making lists of lists.
00047  */
00048 typedef struct list_tag {
00049         struct  list_tag        *next;
00050         LIST    list;
00051 } LIST_ITEM;
00052 
00053 #ifdef  __cplusplus
00054 extern "C" {
00055 #endif
00056 
00057 void listInit(LIST *list);
00058 void listEnqueue(LIST *list, ITEM *item);
00059 ITEM *listDequeue(LIST *list);
00060 int listDelete(LIST *list, ITEM *item);
00061 int listReplace(LIST *list, ITEM *item, ITEM *newItem);
00062 void listPrepend(LIST *list, ITEM *item);
00063 void listFunc(LIST *list, void (*func)(ITEM *));
00064 int listCount(LIST *list);
00065 void listInsert(LIST *list, ITEM *in, int (*func)(ITEM *,ITEM *));
00066 int listIsEmpty(LIST *list);
00067 
00068 #ifdef  __cplusplus
00069 }
00070 #endif
00071 
00072 #endif
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Defines