Main Page | Data Structures | File List | Data Fields | Globals

ioclient.h

Go to the documentation of this file.
00001 /*
00002  *  Copyright (c) Members of the EGEE Collaboration. 2004.
00003  *  See http://eu-egee.org/partners/ for details on the copyright holders.
00004  *  For license conditions see the license file or http://eu-egee.org/license.html
00005  *
00006  *  GLite Data IO Client module: IOClient API
00007  *
00008  *  Authors: Paolo Badino <paolo.badino@cern.ch>
00009  *  Version info: $Id: ioclient.h,v 1.11 2005/10/06 08:44:56 zfarkas Exp $
00010  *  Release: $Name: glite-data-io-client_R_1_5_2 $
00011  *
00012  */
00013 
00014 #ifndef GLITE_DATA_IO_CLIENT_IOCLIENT_H_
00015 #define GLITE_DATA_IO_CLIENT_IOCLIENT_H_
00016 
00017 #include "glite/data/io/client/iotypes.h"
00018 #include <fcntl.h>
00019 
00020 
00021 #ifdef __cplusplus
00022 extern "C" {
00023 #endif //__cplusplus
00024 
00025 /* Service discovery type of gLite I/O */
00026 #define GLITE_IO_SD_TYPE "org.glite.gliteIO"
00027 
00028 /* Environment variable to override Service type */
00029 #define GLITE_IO_SD_ENV  "GLITE_SD_GLITEIO_TYPE"
00030 
00031 /* gLite IO URL prefix */
00032 #define GLITE_IO_URL_PREFIX "gliteio://"
00033 
00034 /* Verbose environment variable */
00035 #define TOOL_USER_VERBOSE "__GLITE_IO_VERBOSE"
00036 
00042 bool is_gliteio_url(const char *string);
00043 
00050 int glite_io_initialize(const char *endpoint, const bool encryptdata);
00051       
00055 void glite_io_finalize();
00056 
00077 glite_handle glite_open(const char * pathname, glite_int32 flags, glite_int32 mode, glite_int64 size, glite_result* result);
00078 
00095 glite_handle glite_creat(const char * pathname, glite_int32 mode, glite_int64 size, glite_result* result);
00096 
00105 glite_int32 glite_read(glite_handle fh, void * buf, glite_int32 count);
00106 
00116 glite_int32 glite_write(glite_handle fh, const void * buf, glite_int32 count);
00117 
00131 glite_int64 glite_lseek(glite_handle fh, glite_int64 offset, glite_int32 whence);
00132 
00141 glite_int32 glite_fstat(glite_handle fh, struct glite_stat * buf);
00142 
00149 glite_int32 glite_close(glite_handle fh);
00150 
00165 glite_int32 glite_unlink(const char * pathname);
00166 
00176 glite_int32 glite_error(glite_handle fh);
00177 
00184 const char * glite_strerror(glite_result error);
00185 
00186 #ifdef __cplusplus
00187 }
00188 #endif //__cplusplus
00189 
00190 #endif //GLITE_DATA_IO_CLIENT_IOCLIENT_H_
The GLite Project. All rights reserved.