xrootd
XrdOfsPrepare.hh
Go to the documentation of this file.
1 #ifndef __XRDOFSPREPARE_H__
2 #define __XRDOFSPREPARE_H__
3 /******************************************************************************/
4 /* */
5 /* X r d O f s P r e p a r e . h h */
6 /* */
7 /* (c) 2019 by the Board of Trustees of the Leland Stanford, Jr., University */
8 /* All Rights Reserved */
9 /* Produced by Andrew Hanushevsky for Stanford University under contract */
10 /* DE-AC02-76-SFO0515 with the Department of Energy */
11 /* */
12 /* This file is part of the XRootD software suite. */
13 /* */
14 /* XRootD is free software: you can redistribute it and/or modify it under */
15 /* the terms of the GNU Lesser General Public License as published by the */
16 /* Free Software Foundation, either version 3 of the License, or (at your */
17 /* option) any later version. */
18 /* */
19 /* XRootD is distributed in the hope that it will be useful, but WITHOUT */
20 /* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */
21 /* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */
22 /* License for more details. */
23 /* */
24 /* You should have received a copy of the GNU Lesser General Public License */
25 /* along with XRootD in a file called COPYING.LESSER (LGPL license) and file */
26 /* COPYING (GPL license). If not, see <http://www.gnu.org/licenses/>. */
27 /* */
28 /* The copyright holder's institutional names and contributor's names may not */
29 /* be used to endorse or promote products derived from this software without */
30 /* specific prior written permission of the institution or contributor. */
31 /******************************************************************************/
32 
33 #include <string>
34 #include <vector>
35 
38 
39 class XrdOss;
40 class XrdOucEnv;
41 class XrdOucErrInfo;
42 class XrdSecEntity;
43 class XrdSfsFileSystem;
44 class XrdSfsPrep;
45 
47 {
48 public:
49 
50 //------------------------------------------------------------------------------
64 //-----------------------------------------------------------------------------
65 
66 virtual int begin( XrdSfsPrep &pargs,
67  XrdOucErrInfo &eInfo,
68  const XrdSecEntity *client = 0) = 0;
69 
70 //------------------------------------------------------------------------------
81 //-----------------------------------------------------------------------------
82 
83 virtual int cancel( XrdSfsPrep &pargs,
84  XrdOucErrInfo &eInfo,
85  const XrdSecEntity *client = 0) = 0;
86 
87 //------------------------------------------------------------------------------
97 //-----------------------------------------------------------------------------
98 
99 virtual int query( XrdSfsPrep &pargs,
100  XrdOucErrInfo &eInfo,
101  const XrdSecEntity *client = 0) = 0;
102 
103 //------------------------------------------------------------------------------
105 //------------------------------------------------------------------------------
106 
108 
109 //------------------------------------------------------------------------------
111 //------------------------------------------------------------------------------
112 
113 virtual ~XrdOfsPrepare() {}
114 };
115 
116 /******************************************************************************/
117 /* X r d O f s g e t P r e p a r e */
118 /******************************************************************************/
119 
120 //------------------------------------------------------------------------------
139 //------------------------------------------------------------------------------
140 
141 class XrdSysError;
142 
143 typedef XrdOfsPrepare *(*XrdOfsgetPrepare_t)(XrdSysError *eDest,
144  const char *confg,
145  const char *parms,
146  XrdSfsFileSystem
147  *theSfs,
148  XrdOss *theOss,
149  XrdOucEnv *envP
150  );
151 
152 #define XrdOfsgetPrepareArguments XrdSysError *eDest,\
153  const char *confg,\
154  const char *parms,\
155  XrdSfsFileSystem\
156  *theSfs,\
157  XrdOss *theOss,\
158  XrdOucEnv *envP
159 /*
160 extern "C" XrdOfsPrepare_t *XrdOfsgetPrepare;
161 */
162 
163 /******************************************************************************/
164 /* X r d O f s A d d P r e p a r e */
165 /******************************************************************************/
166 
167 //------------------------------------------------------------------------------
188 //------------------------------------------------------------------------------
189 
190 typedef XrdOfsPrepare *(*XrdOfsAddPrepare_t)(XrdSysError *eDest,
191  const char *confg,
192  const char *parms,
193  XrdSfsFileSystem
194  *theSfs,
195  XrdOss *theOss,
196  XrdOucEnv *envP,
197  XrdOfsPrepare *prepP
198  );
199 
200 #define XrdOfsAddPrepareArguments XrdSysError *eDest,\
201  const char *confg,\
202  const char *parms,\
203  XrdSfsFileSystem\
204  *theSfs,\
205  XrdOss *theOss,\
206  XrdOucEnv *envP,\
207  XrdOfsPrepare *prepP
208 /*
209 extern "C" XrdOfsPrepare_t *XrdOfsAddPrepare;
210 */
211 
212 //------------------------------------------------------------------------------
218 //------------------------------------------------------------------------------
219 
225 #endif
virtual int query(XrdSfsPrep &pargs, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)=0
virtual int cancel(XrdSfsPrep &pargs, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)=0
XrdOfsPrepare()
Constructor.
Definition: XrdOfsPrepare.hh:107
Definition: XrdSysError.hh:89
Definition: XrdOucErrInfo.hh:100
Definition: XrdOucEnv.hh:41
virtual ~XrdOfsPrepare()
Destructor.
Definition: XrdOfsPrepare.hh:113
Definition: XrdOss.hh:498
virtual int begin(XrdSfsPrep &pargs, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)=0
Definition: XrdSecEntity.hh:63
< Prepare parameters
Definition: XrdSfsInterface.hh:167
Definition: XrdOfsPrepare.hh:46