XrdXrootdAdmin.hh

Go to the documentation of this file.
00001 #ifndef __XROOTDADMIN__
00002 #define __XROOTDADMIN__
00003 /******************************************************************************/
00004 /*                                                                            */
00005 /*                     X r d X r o o t d A d m i n . h h                      */
00006 /*                                                                            */
00007 /* (c) 2005 by the Board of Trustees of the Leland Stanford, Jr., University  */
00008 /*                            All Rights Reserved                             */
00009 /*   Produced by Andrew Hanushevsky for Stanford University under contract    */
00010 /*              DE-AC03-76-SFO0515 with the Department of Energy              */
00011 /******************************************************************************/
00012   
00013 //         $Id: XrdXrootdAdmin.hh 22437 2008-03-04 14:35:16Z rdm $
00014 
00015 #include <stdlib.h>
00016 #include <netinet/in.h>
00017 
00018 #include "Xrd/XrdLinkMatch.hh"
00019 #include "XrdOuc/XrdOucStream.hh"
00020 #include "XProtocol/XProtocol.hh"
00021 
00022 class XrdNetSocket;
00023 class XrdXrootdJob;
00024 
00025 class XrdXrootdAdmin
00026 {
00027 public:
00028 
00029 static void  addJob(const char *jname, XrdXrootdJob *jp);
00030 
00031 static int   Init(XrdSysError *erp, XrdNetSocket *asock);
00032 
00033        void  Login(int socknum);
00034 
00035        void *Start(XrdNetSocket *AdminSock);
00036 
00037        XrdXrootdAdmin() {}
00038       ~XrdXrootdAdmin() {}
00039 
00040 private:
00041 int   do_Abort();
00042 int   do_Cj();
00043 int   do_Cont();
00044 int   do_Disc();
00045 int   do_Login();
00046 int   do_Lsc();
00047 int   do_Lsj();
00048 int   do_Lsj_Xeq(XrdXrootdJob *jp);
00049 int   do_Lsd();
00050 int   do_Msg();
00051 int   do_Pause();
00052 int   do_Red();
00053 char *getMsg(char *msg, int &mlen);
00054 int   getreqID();
00055 int   getTarget(const char *act, char **rest=0);
00056 int   sendErr(int rc, const char *act, const char *msg);
00057 int   sendOK(int sent);
00058 int   sendResp(const char *act, XActionCode anum);
00059 int   sendResp(const char *act, XActionCode anum,
00060                const char *msg, int mlen);
00061 void  Xeq();
00062 
00063 struct JobTable {struct JobTable *Next;
00064                  char            *Jname;
00065                  XrdXrootdJob    *Job;
00066                 };
00067 
00068 static JobTable        *JobList;
00069 
00070 static XrdSysError     *eDest;
00071        XrdOucStream     Stream;
00072        XrdLinkMatch     Target;
00073 
00074 struct usr {kXR_unt16   pad;
00075             kXR_unt16   atn;
00076             kXR_int32   len;
00077             kXR_int32   act;
00078             usr() {pad = 0; atn = htons(kXR_attn);}
00079            ~usr() {}
00080            }            usResp;
00081        char             TraceID[24];
00082        char             reqID[16];
00083 };
00084 #endif

Generated on Tue Jul 5 14:47:03 2011 for ROOT_528-00b_version by  doxygen 1.5.1