Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

nanoftp.h

Go to the documentation of this file.
00001 /*
00002  * nanohttp.c: minimalist FTP implementation to fetch external subsets.
00003  *
00004  * See Copyright for the status of this software.
00005  *
00006  * daniel@veillard.com
00007  */
00008  
00009 #ifndef __NANO_FTP_H__
00010 #define __NANO_FTP_H__
00011 
00012 #include <libxml/xmlversion.h>
00013 
00014 #ifdef LIBXML_FTP_ENABLED
00015 
00016 #ifdef __cplusplus
00017 extern "C" {
00018 #endif
00019 
00038 typedef void (*ftpListCallback) (void *userData,
00039                                  const char *filename, const char *attrib,
00040                                  const char *owner, const char *group,
00041                                  unsigned long size, int links, int year,
00042                                  const char *month, int day, int hour,
00043                                  int minute);
00052 typedef void (*ftpDataCallback) (void *userData,
00053                                  const char *data,
00054                                  int len);
00055 
00056 /*
00057  * Init
00058  */
00059 XMLPUBFUN void XMLCALL
00060         xmlNanoFTPInit          (void);
00061 XMLPUBFUN void XMLCALL  
00062         xmlNanoFTPCleanup       (void);
00063 
00064 /*
00065  * Creating/freeing contexts.
00066  */
00067 XMLPUBFUN void * XMLCALL        
00068         xmlNanoFTPNewCtxt       (const char *URL);
00069 XMLPUBFUN void XMLCALL  
00070         xmlNanoFTPFreeCtxt      (void * ctx);
00071 XMLPUBFUN void * XMLCALL        
00072         xmlNanoFTPConnectTo     (const char *server,
00073                                  int port);
00074 /*
00075  * Opening/closing session connections.
00076  */
00077 XMLPUBFUN void * XMLCALL        
00078         xmlNanoFTPOpen          (const char *URL);
00079 XMLPUBFUN int XMLCALL   
00080         xmlNanoFTPConnect       (void *ctx);
00081 XMLPUBFUN int XMLCALL   
00082         xmlNanoFTPClose         (void *ctx);
00083 XMLPUBFUN int XMLCALL   
00084         xmlNanoFTPQuit          (void *ctx);
00085 XMLPUBFUN void XMLCALL  
00086         xmlNanoFTPScanProxy     (const char *URL);
00087 XMLPUBFUN void XMLCALL  
00088         xmlNanoFTPProxy         (const char *host,
00089                                  int port,
00090                                  const char *user,
00091                                  const char *passwd,
00092                                  int type);
00093 XMLPUBFUN int XMLCALL   
00094         xmlNanoFTPUpdateURL     (void *ctx,
00095                                  const char *URL);
00096 
00097 /*
00098  * Rather internal commands.
00099  */
00100 XMLPUBFUN int XMLCALL   
00101         xmlNanoFTPGetResponse   (void *ctx);
00102 XMLPUBFUN int XMLCALL   
00103         xmlNanoFTPCheckResponse (void *ctx);
00104 
00105 /*
00106  * CD/DIR/GET handlers.
00107  */
00108 XMLPUBFUN int XMLCALL   
00109         xmlNanoFTPCwd           (void *ctx,
00110                                  char *directory);
00111 XMLPUBFUN int XMLCALL   
00112         xmlNanoFTPDele          (void *ctx,
00113                                  char *file);
00114 
00115 XMLPUBFUN int XMLCALL   
00116         xmlNanoFTPGetConnection (void *ctx);
00117 XMLPUBFUN int XMLCALL   
00118         xmlNanoFTPCloseConnection(void *ctx);
00119 XMLPUBFUN int XMLCALL   
00120         xmlNanoFTPList          (void *ctx,
00121                                  ftpListCallback callback,
00122                                  void *userData,
00123                                  char *filename);
00124 XMLPUBFUN int XMLCALL   
00125         xmlNanoFTPGetSocket     (void *ctx,
00126                                  const char *filename);
00127 XMLPUBFUN int XMLCALL   
00128         xmlNanoFTPGet           (void *ctx,
00129                                  ftpDataCallback callback,
00130                                  void *userData,
00131                                  const char *filename);
00132 XMLPUBFUN int XMLCALL   
00133         xmlNanoFTPRead          (void *ctx,
00134                                  void *dest,
00135                                  int len);
00136 
00137 #ifdef __cplusplus
00138 }
00139 #endif /* LIBXML_FTP_ENABLED */
00140 #endif
00141 #endif /* __NANO_FTP_H__ */
00142 

Generated on Wed Mar 16 00:10:27 2005 for Dibbler - a portable DHCPv6 by  doxygen 1.3.9.1