xrootd
Loading...
Searching...
No Matches
XrdNetRegistry.hh
Go to the documentation of this file.
1#ifndef __XRDNETREGISTRY_HH__
2#define __XRDNETREGISTRY_HH__
3/******************************************************************************/
4/* */
5/* X r d N e t R e g i s t r y . h h */
6/* */
7/* (c) 2020 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
35#include "XrdNet/XrdNetUtils.hh"
36
37class XrdNetAddr;
38
40{
41public:
42
43static const char pfx = '%';
44
45//------------------------------------------------------------------------------
60//------------------------------------------------------------------------------
61static
62const char *GetAddrs(const std::string &hSpec,
63 std::vector<XrdNetAddr> &aVec, int *ordn=0,
66
67//------------------------------------------------------------------------------
80//------------------------------------------------------------------------------
81
82static bool Register(const char *hName, const char *hList[], int hLNum,
83 std::string *eText=0, bool rotate=false);
84
85//------------------------------------------------------------------------------
102//------------------------------------------------------------------------------
103
104static bool Register(const char *hName, const char *hList,
105 std::string *eText=0, bool rotate=false);
106
109
110private:
111
112static bool Resolve(const char *hList, std::string *eText=0);
113static bool SetAlias(const char *hAlias, const char *hName, std::string *eText=0);
114};
115#endif
Definition XrdNetAddr.hh:42
Definition XrdNetRegistry.hh:40
static const char * GetAddrs(const std::string &hSpec, std::vector< XrdNetAddr > &aVec, int *ordn=0, XrdNetUtils::AddrOpts opts=XrdNetUtils::allIPMap, int pNum=XrdNetUtils::PortInSpec)
XrdNetRegistry()
Definition XrdNetRegistry.hh:107
static bool Register(const char *hName, const char *hList[], int hLNum, std::string *eText=0, bool rotate=false)
static const char pfx
Registry names must start with this character.
Definition XrdNetRegistry.hh:43
static bool Resolve(const char *hList, std::string *eText=0)
~XrdNetRegistry()
Definition XrdNetRegistry.hh:108
static bool SetAlias(const char *hAlias, const char *hName, std::string *eText=0)
static bool Register(const char *hName, const char *hList, std::string *eText=0, bool rotate=false)
static const int PortInSpec
Definition XrdNetUtils.hh:129
AddrOpts
Definition XrdNetUtils.hh:123
@ allIPMap
Definition XrdNetUtils.hh:123