Main Page
+
Namespaces
Namespace List
+
Namespace Members
+
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
z
+
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Classes
Class List
Class Index
Class Hierarchy
+
Class Members
+
All
:
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
+
Functions
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
+
Variables
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Typedefs
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
+
Enumerator
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Properties
_
a
c
d
e
f
l
m
o
p
s
t
u
v
+
Related Functions
:
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
Package Documentation
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
src
Utilities
LStoreAdaptor
plugins
LStoreStorageMaker.cc
Go to the documentation of this file.
1
#include "
Utilities/StorageFactory/interface/StorageMaker.h
"
2
#include "
Utilities/StorageFactory/interface/StorageMakerFactory.h
"
3
#include "
Utilities/StorageFactory/interface/StorageFactory.h
"
4
#include "
Utilities/LStoreAdaptor/interface/LStoreFile.h
"
5
#include "
FWCore/Utilities/interface/Exception.h
"
6
#include "
FWCore/MessageLogger/interface/MessageLogger.h
"
7
#include <unistd.h>
8
#include <iostream>
9
10
namespace
edm::storage
{
11
class
LStoreStorageMaker
:
public
StorageMaker
{
12
public
:
15
std::unique_ptr<Storage>
open
(
const
std::string
&proto,
16
const
std::string
&
path
,
17
int
mode
,
18
const
AuxSettings
&)
const override
{
19
std::string
fullpath
= proto +
":"
+
path
;
20
return
std::make_unique<LStoreFile>(
fullpath
,
mode
);
21
}
22
23
/* I don't think this is necessary - Melo
24
virtual void stagein (const std::string &proto, const std::string &path)
25
{
26
std::string fullpath(proto + ":" + path);
27
XrdClientAdmin admin(fullpath.c_str());
28
if (admin.Connect())
29
{
30
XrdOucString str(fullpath.c_str());
31
XrdClientUrlSet url(str);
32
admin.Prepare(url.GetFile().c_str(), kXR_stage | kXR_noerrs, 0);
33
}
34
}
35
*/
36
37
bool
check
(
const
std::string
&proto,
38
const
std::string
&
path
,
39
const
AuxSettings
&,
40
IOOffset
*size =
nullptr
)
const override
{
41
std::string
fullpath
= proto +
":"
+
path
;
42
try
{
43
LStoreFile
fileObj(
fullpath
);
// = LStoreFile (fullpath);
44
*size = fileObj.
position
(0,
Storage::END
);
45
}
catch
(
cms::Exception
&
e
) {
46
return
false
;
47
}
48
return
true
;
49
}
50
};
51
}
// namespace edm::storage
52
53
using namespace
edm::storage
;
54
DEFINE_EDM_PLUGIN
(
StorageMakerFactory
,
LStoreStorageMaker
,
"lstore"
);
edm::storage::IOOffset
int64_t IOOffset
Definition:
IOTypes.h:20
edm::storage::LStoreStorageMaker
Definition:
LStoreStorageMaker.cc:11
edm::storage::LStoreStorageMaker::open
std::unique_ptr< Storage > open(const std::string &proto, const std::string &path, int mode, const AuxSettings &) const override
Definition:
LStoreStorageMaker.cc:15
MessageLogger.h
edm::storage::StorageMaker::AuxSettings
Definition:
StorageMaker.h:12
castor_dqm_sourceclient_file_cfg.path
path
Definition:
castor_dqm_sourceclient_file_cfg.py:37
StorageMakerFactory.h
LStoreFile.h
edm::storage::LStoreFile::position
IOOffset position(IOOffset offset, Relative whence=SET) override
Definition:
LStoreFile.cc:265
edm::storage::StorageMaker
Definition:
StorageMaker.h:10
MillePedeFileConverter_cfg.e
e
Definition:
MillePedeFileConverter_cfg.py:37
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::storage::Storage::END
Definition:
Storage.h:22
edm::storage::LStoreStorageMaker::check
bool check(const std::string &proto, const std::string &path, const AuxSettings &, IOOffset *size=nullptr) const override
Definition:
LStoreStorageMaker.cc:37
reco_skim_cfg_mod.fullpath
fullpath
Definition:
reco_skim_cfg_mod.py:202
ALCARECOPromptCalibProdSiPixelAli0T_cff.mode
mode
Definition:
ALCARECOPromptCalibProdSiPixelAli0T_cff.py:96
edmplugin::PluginFactory
Definition:
PluginFactory.h:35
Exception.h
cms::Exception
Definition:
Exception.h:59
edm::storage
Definition:
XMLUtils.h:19
StorageFactory.h
DEFINE_EDM_PLUGIN
#define DEFINE_EDM_PLUGIN(factory, type, name)
Definition:
PluginFactory.h:123
edm::storage::LStoreFile
Definition:
LStoreFile.h:9
StorageMaker.h
Generated for CMSSW Reference Manual by
1.8.14