00001 /* 00002 * $Id: bitzi.h,v 1.7 2005/06/25 01:37:42 daichik Exp $ 00003 * 00004 * Copyright (c) 2004, Alex Bennee <alex@bennee.com> 00005 * 00006 *---------------------------------------------------------------------- 00007 * This file is part of gtk-gnutella. 00008 * 00009 * gtk-gnutella is free software; you can redistribute it and/or modify 00010 * it under the terms of the GNU General Public License as published by 00011 * the Free Software Foundation; either version 2 of the License, or 00012 * (at your option) any later version. 00013 * 00014 * gtk-gnutella is distributed in the hope that it will be useful, 00015 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00016 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00017 * GNU General Public License for more details. 00018 * 00019 * You should have received a copy of the GNU General Public License 00020 * along with gtk-gnutella; if not, write to the Free Software 00021 * Foundation, Inc.: 00022 * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00023 *---------------------------------------------------------------------- 00024 */ 00025 00026 #ifndef _if_core_bitzi_h_ 00027 #define _if_core_bitzi_h_ 00028 00029 #include "common.h" 00030 00037 typedef enum { 00038 BITZI_FJ_UNKNOWN = 0, 00039 BITZI_FJ_DANGEROUS_MISLEADING, 00040 BITZI_FJ_INCOMPLETE_DAMAGED, 00041 BITZI_FJ_SUBSTANDARD, 00042 BITZI_FJ_OVERRATED, 00043 BITZI_FJ_NORMAL, 00044 BITZI_FJ_UNDERRATED, 00045 BITZI_FJ_COMPLETE, 00046 BITZI_FJ_RECOMMENDED, 00047 BITZI_FJ_BEST_VERSION, 00048 00049 NUM_BITZI_FJ 00050 } bitzi_fj_t; 00051 00055 typedef struct { 00056 gchar *urnsha1; 00057 gchar *mime_type; 00058 gchar *mime_desc; 00059 filesize_t size; 00060 bitzi_fj_t judgement; 00061 gfloat goodness; 00062 time_t expiry; 00063 } bitzi_data_t; 00064 00065 #ifdef CORE_SOURCES 00066 00067 /* 00068 * Bitzi Core API declartions 00069 * 00070 * bitzi_query_* are initiated via the gui and will generate 00071 * notification events 00072 * 00073 * bitzi_querycache_* are used internally for gui querys as well as 00074 * from within the core. They do not generate notification events 00075 */ 00076 00077 gpointer bitzi_query_byurnsha1(const gchar *urnsha1); 00078 bitzi_data_t *bitzi_querycache_byurnsha1(const gchar *urnsha1); 00079 00080 #endif /* CORE_SOURCES */ 00081 00082 #endif /* _core_bitzi_h_ */ 00083 /* -*- mode: cc-mode; tab-width:4; -*- */ 00084 /* vi: set ts=4 sw=4 cindent: */