Main Page | Modules | Data Structures | File List | Data Fields | Globals | Related Pages

lcmaps_vo_data.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
00005  * http://eu-egee.org/license.html
00006  */
00007 
00008 /*                                                                                                            
00009  * Copyright (c) 2001 EU DataGrid.                                                                             
00010  * For license conditions see http://www.eu-datagrid.org/license.html                                          
00011  *
00012  * Copyright (c) 2001, 2002 by 
00013  *     Martijn Steenbakkers <martijn@nikhef.nl>,
00014  *     David Groep <davidg@nikhef.nl>,
00015  *     NIKHEF Amsterdam, the Netherlands
00016  */
00017 
00038 #ifndef LCMAPS_VO_DATA_H
00039 #define LCMAPS_VO_DATA_H
00040 
00041 /******************************************************************************
00042                              Define constants
00043 ******************************************************************************/
00044 #define LCMAPS_NO_GID (gid_t)(-1) 
00046 /******************************************************************************
00047                              Include header files
00048 ******************************************************************************/
00049 #include <grp.h>
00050 
00051 /******************************************************************************
00052                                Type definitions
00053 ******************************************************************************/
00054 
00064 typedef struct lcmaps_vo_data_s
00065 {
00066     char * vo;         
00067     char * group;      
00068     char * subgroup;   
00069     char * role;       
00070     char * capability; 
00071 } lcmaps_vo_data_t;
00072 
00082 typedef struct lcmaps_vo_mapping_s
00083 {
00084     char * vostring;   
00085     char * groupname;  
00087     gid_t  gid;        
00089 } lcmaps_vo_mapping_t;
00090 
00091 /******************************************************************************
00092  *                 Module definition
00093  *****************************************************************************/ 
00094 
00095 /*
00096  * VO data section
00097  */
00098 extern lcmaps_vo_data_t *
00099 lcmaps_createVoData(
00100     const char * vo,
00101     const char * group,
00102     const char * subgroup,
00103     const char * role,
00104     const char * capability
00105 );
00106 
00107 extern int
00108 lcmaps_deleteVoData(
00109     lcmaps_vo_data_t ** vo_data
00110 );
00111 
00112 extern int
00113 lcmaps_cleanVoData(
00114     lcmaps_vo_data_t * vo_data
00115 );
00116 
00117 extern int
00118 lcmaps_copyVoData(
00119     lcmaps_vo_data_t * dst_vo_data,
00120     const lcmaps_vo_data_t * src_vo_data
00121 );
00122 
00123 extern int
00124 lcmaps_printVoData(
00125     int debug_level,
00126     const lcmaps_vo_data_t * vo_data
00127 );
00128 
00129 extern int
00130 lcmaps_stringVoData(
00131     const lcmaps_vo_data_t * vo_data,
00132     char * buffer,
00133     int nchars
00134 );
00135 
00136 
00137 /*
00138  * VO group mapping section
00139  */
00140 extern lcmaps_vo_mapping_t *
00141 lcmaps_createVoMapping(
00142     const char * vo_data_string,
00143     const char * groupname,
00144     const gid_t  gid
00145 );
00146 
00147 extern int
00148 lcmaps_deleteVoMapping(
00149     lcmaps_vo_mapping_t ** vo_mapping
00150 );
00151 
00152 extern int
00153 lcmaps_cleanVoMapping(
00154     lcmaps_vo_mapping_t * vo_mapping
00155 );
00156 
00157 extern int
00158 lcmaps_copyVoMapping(
00159     lcmaps_vo_mapping_t * dst_vo_mapping,
00160     const lcmaps_vo_mapping_t * src_vo_mapping
00161 );
00162 
00163 extern int
00164 lcmaps_printVoMapping(
00165     int debug_level,
00166     const lcmaps_vo_mapping_t * vo_mapping
00167 );
00168 
00169 #endif /* LCMAPS_VO_DATA_H */
00170 
00171 /******************************************************************************
00172 CVS Information:
00173     $Source: /cvs/jra1mw/org.glite.security.lcmaps/interface/lcmaps_vo_data.h,v $
00174     $Date: 2004/12/02 17:32:05 $
00175     $Revision: 1.3 $
00176     $Author: msteenba $
00177 ******************************************************************************/

Generated on Sun May 29 21:22:11 2005 for lcmaps by doxygen 1.3.5