/**********************************************************************
 
	Copyright (C) 2003 Hirohisa MORI <joshua@nichibun.ac.jp>
 
	This program is free software; you can redistribute it 
	and/or modify it under the terms of the GLOBALBASE 
	Library General Public License (G-LGPL) as published by 

	http://www.globalbase.org/
 
	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.

**********************************************************************/



#ifndef ___PROXY_H___
#define ___PROXY_H___


#include	"xl.h"

typedef struct server_list {
	struct server_list *	next;
	char			type;
	char *			name;
} SERVER_LIST;

typedef struct proxy_info {
	char			proxy_type;
			/* same to XL_INTERPRETER->proxy_type */
	char *			proxy_server;
	int			proxy_port;
	SERVER_LIST *		da_servers;
} PROXY_INFO;


void set_proxy(char type,char * server,int port);
void set_direct_access(char type,char * server);
XL_SEXP * get_proxyinfo();
void check_proxy(PROXY_INFO * info,char * server);
void free_server_list(SERVER_LIST * sl);

#endif

