xrootd
XrdSfsInterface.hh
Go to the documentation of this file.
1#ifndef __SFS_INTERFACE_H__
2#define __SFS_INTERFACE_H__
3/******************************************************************************/
4/* */
5/* X r d S f s I n t e r f a c e . h h */
6/* */
7/* (c) 2010 by the Board of Trustees of the Leland Stanford, Jr., University */
8/* Produced by Andrew Hanushevsky for Stanford University under contract */
9/* DE-AC02-76-SFO0515 with the Department of Energy */
10/* */
11/* This file is part of the XRootD software suite. */
12/* */
13/* XRootD is free software: you can redistribute it and/or modify it under */
14/* the terms of the GNU Lesser General Public License as published by the */
15/* Free Software Foundation, either version 3 of the License, or (at your */
16/* option) any later version. */
17/* */
18/* XRootD is distributed in the hope that it will be useful, but WITHOUT */
19/* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or */
20/* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public */
21/* License for more details. */
22/* */
23/* You should have received a copy of the GNU Lesser General Public License */
24/* along with XRootD in a file called COPYING.LESSER (LGPL license) and file */
25/* COPYING (GPL license). If not, see <http://www.gnu.org/licenses/>. */
26/* */
27/* The copyright holder's institutional names and contributor's names may not */
28/* be used to endorse or promote products derived from this software without */
29/* specific prior written permission of the institution or contributor. */
30/******************************************************************************/
31
32#include <string.h> // For strlcpy()
33#include <errno.h>
34#include <sys/types.h>
35#include <sys/stat.h>
36
38#include "XrdOuc/XrdOucIOVec.hh"
39#include "XrdOuc/XrdOucSFVec.hh"
40
41/******************************************************************************/
42/* O p e n M o d e s */
43/******************************************************************************/
44
45#define SFS_O_RDONLY 0 // open read/only
46#define SFS_O_WRONLY 1 // open write/only
47#define SFS_O_RDWR 2 // open read/write
48#define SFS_O_CREAT 0x100 // used for file creation
49#define SFS_O_TRUNC 0x200 // used for file truncation
50#define SFS_O_MULTIW 0x400 // used for multi-write locations
51#define SFS_O_POSC 0x0100000 // persist on successful close
52#define SFS_O_FORCE 0x0200000 // used for locate only
53#define SFS_O_HNAME 0x0400000 // used for locate only
54#define SFS_O_LOCAL 0x0800000 // used for locate only (local cmd)
55#define SFS_O_NOWAIT 0x01000000 // do not impose operational delays
56#define SFS_O_RAWIO 0x02000000 // allow client-side decompression
57#define SFS_O_RESET 0x04000000 // Reset any cached information
58#define SFS_O_REPLICA 0x08000000 // Open for replication
59
60// The following flag may be set in the access mode arg for open() & mkdir()
61// Note that on some systems mode_t is 16-bits so we use a careful value!
62//
63#define SFS_O_MKPTH 0x00004000 // Make directory path if missing
64
65// The following options are here to provide a uniform clustering interface.
66// They may be passed through open/locate/stat, as applicable.
67//
68#define SFS_O_LOCATE 0x10000000 // This request generated by locate()
69#define SFS_O_STAT 0x20000000 // This request generated by stat()
70#define SFS_O_META 0x40000000 // This request generated by metaop
71
72/******************************************************************************/
73/* D e f i n e s */
74/******************************************************************************/
75
76// Common fctl command values (0 to 255)
77//
78#define SFS_FCTL_GETFD 1 // Return file descriptor if possible
79#define SFS_FCTL_STATV 2 // Return visa information
80#define SFS_FCTL_SPEC1 3 // Return implementation defined information
81
82#define SFS_SFIO_FDVAL 0x80000000 // Use SendData() method GETFD response value
83
84// Common fsctl command values (0 to 255)
85//
86#define SFS_FSCTL_CMD 255
87
88#define SFS_FSCTL_LOCATE 1 // Locate a file
89#define SFS_FSCTL_STATFS 2 // Return FS data
90#define SFS_FSCTL_STATLS 3 // Return LS data
91#define SFS_FSCTL_STATXA 4 // Return XA data
92#define SFS_FSCTL_STATCC 5 // Return Cluster Config status
93#define SFS_FSCTL_PLUGIN 8 // Return Implementation Dependent Data
94#define SFS_FSCTL_PLUGIO 16 // Return Implementation Dependent Data
95
96// Return values for integer & XrdSfsXferSize returning XrdSfs methods
97//
98#define SFS_STALL 1 // Return value -> Seconds to stall client
99#define SFS_OK 0 // ErrInfo code -> All is well
100#define SFS_ERROR -1 // ErrInfo code -> Error occurred
101#define SFS_REDIRECT -256 // ErrInfo code -> Port number to redirect to
102#define SFS_STARTED -512 // ErrInfo code -> Estimated seconds to completion
103#define SFS_DATA -1024 // ErrInfo code -> Length of data
104#define SFS_DATAVEC -2048 // ErrInfo code -> Num iovec elements in msgbuff
105
106// The following macros are used for dealing with special local paths
107//
108#define SFS_LCLPRFX "/=/"
109#define SFS_LCLPLEN 3
110#define SFS_LCLPATH(x) !strncmp(x, SFS_LCLPRFX, SFS_LCLPLEN)
111#define SFS_LCLPRFY "/="
112#define SFS_LCLROOT(x) !strncmp(x, SFS_LCLPRFX, SFS_LCLPLEN-1) \
113 && (*(x+SFS_LCLPLEN-1) == '/' || *(x+SFS_LCLPLEN-1) == 0)
114
115/******************************************************************************/
116/* S t r u c t u r e s & T y p e d e f s */
117/******************************************************************************/
118
119typedef long long XrdSfsFileOffset;
121typedef int XrdSfsMode;
122typedef int XrdSfsXferSize;
123
125{
132//------------------------------------------------
133
134#define Prep_PRTY0 0
135#define Prep_PRTY1 1
136#define Prep_PRTY2 2
137#define Prep_PRTY3 3
138#define Prep_PMASK 3
139#define Prep_SENDAOK 4
140#define Prep_SENDERR 8
141#define Prep_SENDACK 12
142#define Prep_WMODE 16
143#define Prep_STAGE 32
144#define Prep_COLOC 64
145#define Prep_FRESH 128
146#define Prep_CANCEL 256
147#define Prep_QUERY 512
148#define Prep_EVICT 1024
149
150class XrdOucTList;
151
153{
154 const char *Arg1;
157 const char *Arg2;
158};
159
161{
162 char *reqid;
163 char *notify;
164 int opts;
167};
168
169/******************************************************************************/
170/* A b s t r a c t C l a s s e s */
171/******************************************************************************/
172
173class XrdSfsFile;
174class XrdSfsDirectory;
175class XrdOucEnv;
176class XrdOucTList;
177class XrdSecEntity;
178
179/******************************************************************************/
180/* X r d S f s F i l e S y s t e m */
181/******************************************************************************/
182
183//-----------------------------------------------------------------------------
207//-----------------------------------------------------------------------------
208
210{
211public:
212
213//-----------------------------------------------------------------------------
223//-----------------------------------------------------------------------------
224
225virtual XrdSfsDirectory *newDir(char *user=0, int MonID=0) = 0;
226
227//-----------------------------------------------------------------------------
237//-----------------------------------------------------------------------------
238
239virtual XrdSfsFile *newFile(char *user=0, int MonID=0) = 0;
240
241//-----------------------------------------------------------------------------
260//-----------------------------------------------------------------------------
261
263
264virtual int chksum( csFunc Func,
265 const char *csName,
266 const char *path,
267 XrdOucErrInfo &eInfo,
268 const XrdSecEntity *client = 0,
269 const char *opaque = 0)
270{
271 (void)Func; (void)csName; (void)path; (void)eInfo; (void)client;
272 (void)opaque;
273 eInfo.setErrInfo(ENOTSUP, "Not supported.");
274 return SFS_ERROR;
275}
276
277//-----------------------------------------------------------------------------
287//-----------------------------------------------------------------------------
288
289virtual int chmod(const char *path,
290 XrdSfsMode mode,
291 XrdOucErrInfo &eInfo,
292 const XrdSecEntity *client = 0,
293 const char *opaque = 0) = 0;
294
295//-----------------------------------------------------------------------------
299//-----------------------------------------------------------------------------
300
301virtual void Disc(const XrdSecEntity *client = 0)
302{
303 (void)client;
304}
305
306//-----------------------------------------------------------------------------
311//-----------------------------------------------------------------------------
312
313virtual void EnvInfo(XrdOucEnv *envP)
314{
315 (void)envP;
316}
317
318//-----------------------------------------------------------------------------
346//-----------------------------------------------------------------------------
347
348virtual int FSctl(const int cmd,
349 XrdSfsFSctl &args,
350 XrdOucErrInfo &eInfo,
351 const XrdSecEntity *client = 0)
352{
353 (void)cmd; (void)args; (void)eInfo; (void)client;
354 return SFS_OK;
355}
356
357//-----------------------------------------------------------------------------
373//-----------------------------------------------------------------------------
374
375virtual int fsctl(const int cmd,
376 const char *args,
377 XrdOucErrInfo &eInfo,
378 const XrdSecEntity *client = 0) = 0;
379
380//-----------------------------------------------------------------------------
390//-----------------------------------------------------------------------------
391
392virtual int getStats(char *buff, int blen) = 0;
393
394//-----------------------------------------------------------------------------
398//-----------------------------------------------------------------------------
399
400virtual const char *getVersion() = 0;
401
402//-----------------------------------------------------------------------------
418//-----------------------------------------------------------------------------
419
420virtual int exists(const char *path,
421 XrdSfsFileExistence &eFlag,
422 XrdOucErrInfo &eInfo,
423 const XrdSecEntity *client = 0,
424 const char *opaque = 0) = 0;
425
426//-----------------------------------------------------------------------------
436//-----------------------------------------------------------------------------
437
438virtual int mkdir(const char *path,
439 XrdSfsMode mode,
440 XrdOucErrInfo &eInfo,
441 const XrdSecEntity *client = 0,
442 const char *opaque = 0) = 0;
443
444//-----------------------------------------------------------------------------
452//-----------------------------------------------------------------------------
453
454virtual int prepare( XrdSfsPrep &pargs,
455 XrdOucErrInfo &eInfo,
456 const XrdSecEntity *client = 0) = 0;
457
458//-----------------------------------------------------------------------------
467//-----------------------------------------------------------------------------
468
469virtual int rem(const char *path,
470 XrdOucErrInfo &eInfo,
471 const XrdSecEntity *client = 0,
472 const char *opaque = 0) = 0;
473
474//-----------------------------------------------------------------------------
483//-----------------------------------------------------------------------------
484
485virtual int remdir(const char *path,
486 XrdOucErrInfo &eInfo,
487 const XrdSecEntity *client = 0,
488 const char *opaque = 0) = 0;
489
490//-----------------------------------------------------------------------------
501//-----------------------------------------------------------------------------
502
503virtual int rename(const char *oPath,
504 const char *nPath,
505 XrdOucErrInfo &eInfo,
506 const XrdSecEntity *client = 0,
507 const char *opaqueO = 0,
508 const char *opaqueN = 0) = 0;
509
510//-----------------------------------------------------------------------------
521//-----------------------------------------------------------------------------
522
523virtual int stat(const char *Name,
524 struct stat *buf,
525 XrdOucErrInfo &eInfo,
526 const XrdSecEntity *client = 0,
527 const char *opaque = 0) = 0;
528
529//-----------------------------------------------------------------------------
541//-----------------------------------------------------------------------------
542
543virtual int stat(const char *path,
544 mode_t &mode,
545 XrdOucErrInfo &eInfo,
546 const XrdSecEntity *client = 0,
547 const char *opaque = 0) = 0;
548
549//-----------------------------------------------------------------------------
559//-----------------------------------------------------------------------------
560
561virtual int truncate(const char *path,
562 XrdSfsFileOffset fsize,
563 XrdOucErrInfo &eInfo,
564 const XrdSecEntity *client = 0,
565 const char *opaque = 0) = 0;
566
567//-----------------------------------------------------------------------------
569//-----------------------------------------------------------------------------
570
573};
574
575/******************************************************************************/
576/* F i l e S y s t e m I n s t a n t i a t o r */
577/******************************************************************************/
578
579//-----------------------------------------------------------------------------
613typedef XrdSfsFileSystem *(*XrdSfsFileSystem_t) (XrdSfsFileSystem *nativeFS,
614 XrdSysLogger *Logger,
615 const char *configFn);
616
617typedef XrdSfsFileSystem *(*XrdSfsFileSystem2_t)(XrdSfsFileSystem *nativeFS,
618 XrdSysLogger *Logger,
619 const char *configFn,
620 XrdOucEnv *envP);
621
622//-----------------------------------------------------------------------------
623
624//------------------------------------------------------------------------------
636//------------------------------------------------------------------------------
637
638/******************************************************************************/
639/* X r d S f s F i l e */
640/******************************************************************************/
641
642//------------------------------------------------------------------------------
645//------------------------------------------------------------------------------
646
647class XrdSfsAio;
648class XrdSfsDio;
649class XrdSfsXio;
650
652{
653public:
654
655//-----------------------------------------------------------------------------
658//-----------------------------------------------------------------------------
659
661
662//-----------------------------------------------------------------------------
683//-----------------------------------------------------------------------------
684
685virtual int open(const char *fileName,
686 XrdSfsFileOpenMode openMode,
687 mode_t createMode,
688 const XrdSecEntity *client = 0,
689 const char *opaque = 0) = 0;
690
691//-----------------------------------------------------------------------------
695//-----------------------------------------------------------------------------
696
697virtual int close() = 0;
698
699//-----------------------------------------------------------------------------
716//-----------------------------------------------------------------------------
717
718virtual int fctl(const int cmd,
719 const char *args,
720 XrdOucErrInfo &eInfo) = 0;
721
722//-----------------------------------------------------------------------------
735//-----------------------------------------------------------------------------
736
737virtual int fctl(const int cmd,
738 int alen,
739 const char *args,
740 const XrdSecEntity *client = 0)
741{
742 (void)cmd; (void)alen; (void)args; (void)client;
743 return SFS_OK;
744}
745
746//-----------------------------------------------------------------------------
750//-----------------------------------------------------------------------------
751
752virtual const char *FName() = 0;
753
754
755//-----------------------------------------------------------------------------
762//-----------------------------------------------------------------------------
763
764virtual int getMmap(void **Addr, off_t &Size) = 0;
765
766//-----------------------------------------------------------------------------
774//-----------------------------------------------------------------------------
775
777 XrdSfsXferSize size) = 0;
778
779//-----------------------------------------------------------------------------
788//-----------------------------------------------------------------------------
789
791 char *buffer,
792 XrdSfsXferSize size) = 0;
793
794//-----------------------------------------------------------------------------
801//-----------------------------------------------------------------------------
802
803virtual XrdSfsXferSize read(XrdSfsAio *aioparm) = 0;
804
805//-----------------------------------------------------------------------------
815//-----------------------------------------------------------------------------
816
818 int rdvCnt)
819 {XrdSfsXferSize rdsz, totbytes = 0;
820 for (int i = 0; i < rdvCnt; i++)
821 {rdsz = read(readV[i].offset,
822 readV[i].data, readV[i].size);
823 if (rdsz != readV[i].size)
824 {if (rdsz < 0) return rdsz;
825 error.setErrInfo(ESPIPE,"read past eof");
826 return SFS_ERROR;
827 }
828 totbytes += rdsz;
829 }
830 return totbytes;
831 }
832
833//-----------------------------------------------------------------------------
843//-----------------------------------------------------------------------------
844
845virtual int SendData(XrdSfsDio *sfDio,
846 XrdSfsFileOffset offset,
847 XrdSfsXferSize size)
848{
849 (void)sfDio; (void)offset; (void)size;
850 return SFS_OK;
851}
852
853//-----------------------------------------------------------------------------
862//-----------------------------------------------------------------------------
863
865 const char *buffer,
866 XrdSfsXferSize size) = 0;
867
868//-----------------------------------------------------------------------------
875//-----------------------------------------------------------------------------
876
877virtual int write(XrdSfsAio *aioparm) = 0;
878
879//-----------------------------------------------------------------------------
889//-----------------------------------------------------------------------------
890
892 int wdvCnt)
893 {XrdSfsXferSize wrsz, totbytes = 0;
894 for (int i = 0; i < wdvCnt; i++)
895 {wrsz = write(writeV[i].offset,
896 writeV[i].data, writeV[i].size);
897 if (wrsz != writeV[i].size)
898 {if (wrsz < 0) return wrsz;
899 error.setErrInfo(ESPIPE,"write past eof");
900 return SFS_ERROR;
901 }
902 totbytes += wrsz;
903 }
904 return totbytes;
905 }
906
907//-----------------------------------------------------------------------------
914//-----------------------------------------------------------------------------
915
916virtual int stat(struct stat *buf) = 0;
917
918//-----------------------------------------------------------------------------
922//-----------------------------------------------------------------------------
923
924virtual int sync() = 0;
925
926//-----------------------------------------------------------------------------
931//-----------------------------------------------------------------------------
932
933virtual int sync(XrdSfsAio *aiop) = 0;
934
935//-----------------------------------------------------------------------------
941//-----------------------------------------------------------------------------
942
943virtual int truncate(XrdSfsFileOffset fsize) = 0;
944
945//-----------------------------------------------------------------------------
953//-----------------------------------------------------------------------------
954
955virtual int getCXinfo(char cxtype[4], int &cxrsz) = 0;
956
957//-----------------------------------------------------------------------------
961//-----------------------------------------------------------------------------
962
963virtual void setXio(XrdSfsXio *xioP) { (void)xioP; }
964
965//-----------------------------------------------------------------------------
972//-----------------------------------------------------------------------------
973
974 XrdSfsFile(const char *user=0, int MonID=0)
975 : error(user, MonID) {}
976
977//-----------------------------------------------------------------------------
979//-----------------------------------------------------------------------------
980
981virtual ~XrdSfsFile() {}
982
983}; // class XrdSfsFile
984
985/******************************************************************************/
986/* X r d S f s D i r e c t o r y */
987/******************************************************************************/
988
989//------------------------------------------------------------------------------
992//------------------------------------------------------------------------------
993
995{
996public:
997
998//-----------------------------------------------------------------------------
1001//-----------------------------------------------------------------------------
1002
1004
1005//-----------------------------------------------------------------------------
1013//-----------------------------------------------------------------------------
1014
1015virtual int open(const char *path,
1016 const XrdSecEntity *client = 0,
1017 const char *opaque = 0) = 0;
1018
1019//-----------------------------------------------------------------------------
1027//-----------------------------------------------------------------------------
1028
1029virtual const char *nextEntry() = 0;
1030
1031//-----------------------------------------------------------------------------
1035//-----------------------------------------------------------------------------
1036
1037virtual int close() = 0;
1038
1039//-----------------------------------------------------------------------------
1043//-----------------------------------------------------------------------------
1044
1045virtual const char *FName() = 0;
1046
1047//-----------------------------------------------------------------------------
1053//-----------------------------------------------------------------------------
1054
1055virtual int autoStat(struct stat *buf)
1056 {(void)buf;
1057 error.setErrInfo(ENOTSUP, "Not supported.");
1058 return SFS_ERROR;
1059 }
1060
1061//-----------------------------------------------------------------------------
1068//-----------------------------------------------------------------------------
1069
1070 XrdSfsDirectory(const char *user=0, int MonID=0)
1071 : error(user, MonID) {}
1072
1073//-----------------------------------------------------------------------------
1075//-----------------------------------------------------------------------------
1076
1078
1079}; // class XrdSfsDirectory
1080#endif
#define stat(a, b)
Definition: XrdPosix.hh:96
int XrdSfsMode
Definition: XrdSfsInterface.hh:121
#define SFS_ERROR
Definition: XrdSfsInterface.hh:100
XrdSfsFileExistence
Definition: XrdSfsInterface.hh:125
@ XrdSfsFileExistIsOther
Definition: XrdSfsInterface.hh:130
@ XrdSfsFileExistIsFile
Definition: XrdSfsInterface.hh:127
@ XrdSfsFileExistNo
Definition: XrdSfsInterface.hh:126
@ XrdSfsFileExistIsOffline
Definition: XrdSfsInterface.hh:129
@ XrdSfsFileExistIsDirectory
Definition: XrdSfsInterface.hh:128
int XrdSfsFileOpenMode
Definition: XrdSfsInterface.hh:120
#define SFS_OK
Definition: XrdSfsInterface.hh:99
long long XrdSfsFileOffset
Definition: XrdSfsInterface.hh:119
int XrdSfsXferSize
Definition: XrdSfsInterface.hh:122
Definition: XrdOucEnv.hh:42
Definition: XrdOucErrInfo.hh:100
int setErrInfo(int code, const char *emsg)
Definition: XrdOucErrInfo.hh:146
Definition: XrdOucTList.hh:42
Definition: XrdSecEntity.hh:52
Definition: XrdSfsAio.hh:58
Definition: XrdSfsDio.hh:47
Definition: XrdSfsInterface.hh:995
XrdOucErrInfo error
Definition: XrdSfsInterface.hh:1003
virtual int autoStat(struct stat *buf)
Definition: XrdSfsInterface.hh:1055
XrdSfsDirectory(const char *user=0, int MonID=0)
Definition: XrdSfsInterface.hh:1070
virtual ~XrdSfsDirectory()
Destructor.
Definition: XrdSfsInterface.hh:1077
virtual int open(const char *path, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual const char * FName()=0
virtual const char * nextEntry()=0
virtual int close()=0
Definition: XrdSfsInterface.hh:210
XrdSfsFileSystem()
Constructor and Destructor.
Definition: XrdSfsInterface.hh:571
virtual int chmod(const char *path, XrdSfsMode mode, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual void EnvInfo(XrdOucEnv *envP)
Definition: XrdSfsInterface.hh:313
virtual int stat(const char *path, mode_t &mode, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual void Disc(const XrdSecEntity *client=0)
Definition: XrdSfsInterface.hh:301
virtual int getStats(char *buff, int blen)=0
virtual int fsctl(const int cmd, const char *args, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)=0
virtual int rename(const char *oPath, const char *nPath, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaqueO=0, const char *opaqueN=0)=0
virtual int mkdir(const char *path, XrdSfsMode mode, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual const char * getVersion()=0
virtual ~XrdSfsFileSystem()
Definition: XrdSfsInterface.hh:572
virtual XrdSfsFile * newFile(char *user=0, int MonID=0)=0
virtual int truncate(const char *path, XrdSfsFileOffset fsize, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual int remdir(const char *path, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual int FSctl(const int cmd, XrdSfsFSctl &args, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)
Definition: XrdSfsInterface.hh:348
csFunc
Definition: XrdSfsInterface.hh:262
@ csGet
Definition: XrdSfsInterface.hh:262
@ csCalc
Definition: XrdSfsInterface.hh:262
@ csSize
Definition: XrdSfsInterface.hh:262
virtual int exists(const char *path, XrdSfsFileExistence &eFlag, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual int prepare(XrdSfsPrep &pargs, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0)=0
virtual int stat(const char *Name, struct stat *buf, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual int rem(const char *path, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual XrdSfsDirectory * newDir(char *user=0, int MonID=0)=0
virtual int chksum(csFunc Func, const char *csName, const char *path, XrdOucErrInfo &eInfo, const XrdSecEntity *client=0, const char *opaque=0)
Definition: XrdSfsInterface.hh:264
Definition: XrdSfsInterface.hh:652
virtual int sync()=0
virtual int fctl(const int cmd, int alen, const char *args, const XrdSecEntity *client=0)
Definition: XrdSfsInterface.hh:737
virtual int getMmap(void **Addr, off_t &Size)=0
virtual int open(const char *fileName, XrdSfsFileOpenMode openMode, mode_t createMode, const XrdSecEntity *client=0, const char *opaque=0)=0
virtual int sync(XrdSfsAio *aiop)=0
virtual int SendData(XrdSfsDio *sfDio, XrdSfsFileOffset offset, XrdSfsXferSize size)
Definition: XrdSfsInterface.hh:845
virtual XrdSfsXferSize read(XrdSfsAio *aioparm)=0
virtual XrdSfsXferSize writev(XrdOucIOVec *writeV, int wdvCnt)
Definition: XrdSfsInterface.hh:891
virtual int write(XrdSfsAio *aioparm)=0
virtual XrdSfsXferSize read(XrdSfsFileOffset offset, XrdSfsXferSize size)=0
virtual int truncate(XrdSfsFileOffset fsize)=0
virtual ~XrdSfsFile()
Destructor.
Definition: XrdSfsInterface.hh:981
virtual XrdSfsXferSize read(XrdSfsFileOffset offset, char *buffer, XrdSfsXferSize size)=0
virtual const char * FName()=0
virtual int getCXinfo(char cxtype[4], int &cxrsz)=0
XrdSfsFile(const char *user=0, int MonID=0)
Definition: XrdSfsInterface.hh:974
XrdOucErrInfo error
Definition: XrdSfsInterface.hh:660
virtual XrdSfsXferSize readv(XrdOucIOVec *readV, int rdvCnt)
Definition: XrdSfsInterface.hh:817
virtual int stat(struct stat *buf)=0
virtual void setXio(XrdSfsXio *xioP)
Definition: XrdSfsInterface.hh:963
virtual int fctl(const int cmd, const char *args, XrdOucErrInfo &eInfo)=0
virtual XrdSfsXferSize write(XrdSfsFileOffset offset, const char *buffer, XrdSfsXferSize size)=0
virtual int close()=0
Definition: XrdSfsXio.hh:81
Definition: XrdSysLogger.hh:53
Definition: XrdOucIOVec.hh:41
< SFS_FSCTL_PLUGIN/PLUGIO parameters
Definition: XrdSfsInterface.hh:153
const char * Arg1
PLUGIO & PLUGIN.
Definition: XrdSfsInterface.hh:154
int Arg2Len
Length.
Definition: XrdSfsInterface.hh:156
const char * Arg2
PLUGIN opaque string.
Definition: XrdSfsInterface.hh:157
int Arg1Len
Length.
Definition: XrdSfsInterface.hh:155
< Prepare parameters
Definition: XrdSfsInterface.hh:161
char * notify
Notification path or 0.
Definition: XrdSfsInterface.hh:163
XrdOucTList * paths
List of paths.
Definition: XrdSfsInterface.hh:165
XrdOucTList * oinfo
1-to-1 correspondence of opaque info
Definition: XrdSfsInterface.hh:166
char * reqid
Request ID.
Definition: XrdSfsInterface.hh:162
int opts
Prep_xxx.
Definition: XrdSfsInterface.hh:164