/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */ /* g-yaz-client.h * * This program is free software; you can redistribute it and/or * modify it under the terms of version 2 of the GNU General Public * License as published by the Free Software Foundation. * * 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, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. * * Author: * Fernando Alencar Marostica * */ #ifndef __G_YAZ_CLIENT_H__ #define __G_YAZ_CLIENT_H__ #include #include #include #include #include G_BEGIN_DECLS #define G_TYPE_YAZ_CLIENT (g_yaz_client_get_type()) #define G_YAZ_CLIENT(obj) (G_CHECK_CAST ((obj), G_TYPE_YAZ_CLIENT, GYazClient) #define G_YAZ_CLIENT_CLASS(klass) (G_CHECK_CLASS_CAST ((klass), G_TYPE_YAZ_CLIENT, GYazClientClass) #define G_IS_YAZ_CLIENT(obj) (G_CHECK_TYPE ((obj), G_TYPE_YAZ_CLIENT) #define G_IS_YAZ_CLIENT_CLASS(klass) (G_CHECK_CLASS_TYPE ((klass), G_TYPE_YAZ_CLIENT) typedef struct _GYazClient GYazClient; typedef struct _GYazClientClass GYazClientClass; struct _GYazClient { GObject parent_object; const char *host; int portnum; ZOOM_options options; ZOOM_connection connection; ZOOM_resultset resultset; }; struct _GYazClientClass { GObjectClass parent_class; }; GType g_yaz_client_get_type (void); GYazClient g_yaz_client_new (void); ZOOM_connection g_yaz_client_connection_new (const char *host, int portnum); ZOOM_connection g_yaz_client_create_connection (ZOOM_options options); void g_yaz_client_connection_connect (ZOOM_connection c, const char *host, int portnum); void g_yaz_client_connection_destroy (ZOOM_connection c); void g_yaz_client_connection_set_option (ZOOM_connection c, const char *key, const char *value); void g_yaz_client_connection_get_option (ZOOM_connection c, const char *key); int g_yaz_client_connection_error (ZOOM_connection c, const char **cp, const char **addinfo); int g_yaz_client_connection_error_x (ZOOM_connection c, const char **cp, const char **addinfo, const char **dset); G_END_DECLS #endif /* __G_YAZ_CLIENT_H__ */