xrootd
Main Page
Namespaces
Classes
Files
File List
File Members
src
XrdCms
XrdCmsNash.hh
Go to the documentation of this file.
1
#ifndef __XRDCMSNASH_HH__
2
#define __XRDCMSNASH_HH__
3
/******************************************************************************/
4
/* */
5
/* X r d C m s N a s h . h h */
6
/* */
7
/* (c) 2007 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
13
// $Id$
14
15
#include "
XrdCms/XrdCmsKey.hh
"
16
17
class
XrdCmsNash
18
{
19
public
:
20
XrdCmsKeyItem
*
Add
(
XrdCmsKey
&Key);
21
22
XrdCmsKeyItem
*
Find
(
XrdCmsKey
&Key);
23
24
int
Recycle
(
XrdCmsKeyItem
*rip);
25
26
// When allocateing a new nash, specify the required starting size. Make
27
// sure that the previous number is the correct Fibonocci antecedent. The
28
// series is simply n[j] = n[j-1] + n[j-2].
29
//
30
XrdCmsNash
(
int
psize = 17711,
int
size = 28657);
31
~XrdCmsNash
() {}
// Never gets deleted
32
33
private
:
34
35
static
const
int
LoadMax
= 80;
36
37
void
Expand
();
38
39
XrdCmsKeyItem
**
nashtable
;
40
int
prevtablesize
;
41
int
nashtablesize
;
42
int
nashnum
;
43
int
Threshold
;
44
};
45
#endif
Generated by
1.8.1.2