soap-router.h

Go to the documentation of this file.
00001 /******************************************************************
00002  *  $Id: soap-router.h,v 1.11 2006/11/23 15:27:33 m0gg Exp $
00003  *
00004  * CSOAP Project:  A SOAP client/server library in C
00005  * Copyright (C) 2003  Ferhat Ayaz
00006  *
00007  * This library is free software; you can redistribute it and/or
00008  * modify it under the terms of the GNU Library General Public
00009  * License as published by the Free Software Foundation; either
00010  * version 2 of the License, or (at your option) any later version.
00011  *
00012  * This library is distributed in the hope that it will be useful,
00013  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00014  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00015  * Library General Public License for more details.
00016  *
00017  * You should have received a copy of the GNU Library General Public
00018  * License along with this library; if not, write to the
00019  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
00020  * Boston, MA  02111-1307, USA.
00021  * 
00022  * Email: ayaz@jprogrammer.net
00023  ******************************************************************/
00024 #ifndef __csoap_router_h
00025 #define __csoap_router_h
00026 
00032 typedef int (*soap_auth) (struct SoapEnv *request, const char *user, const char *pass);
00033 
00040 struct SoapRouter
00041 {
00042   SoapServiceNode *service_head;
00043   SoapServiceNode *service_tail;
00044   SoapService *default_service;
00045   soap_auth auth;
00046   xmlDocPtr description;
00047 };
00048 
00049 #ifdef __cplusplus
00050 extern "C" {
00051 #endif
00052 
00065 extern struct SoapRouter *soap_router_new(void);
00066 
00079 extern herror_t soap_router_register_service(struct SoapRouter *router, SoapServiceFunc func, const char *method, const char *urn);
00080 
00086 extern herror_t soap_router_register_default_service(struct SoapRouter * router, SoapServiceFunc func, const char *method, const char *urn);
00087 
00093 extern void soap_router_register_description(struct SoapRouter *router, xmlDocPtr doc);
00094 
00100 extern void soap_router_register_security(struct SoapRouter *router, soap_auth auth);
00101 
00113 extern SoapService *soap_router_find_service(struct SoapRouter *router, const char *urn, const char *method);
00114 
00124 extern void soap_router_free(struct SoapRouter * router);
00125 
00126 #ifdef __cplusplus
00127 }
00128 #endif
00129 
00130 #endif

Generated on Thu Jan 25 23:36:03 2007 for csoap by  doxygen 1.4.6