Geant4
10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
DefaultHepRepTypeTree.cc
Go to the documentation of this file.
1
// Copyright FreeHEP, 2005.
2
3
#include <iostream>
4
5
#include "
cheprep/DefaultHepRepTypeTree.h
"
6
7
using namespace
std;
8
using namespace
HEPREP
;
9
10
/**
11
* @author Mark Donszelmann
12
*/
13
namespace
cheprep
{
14
15
DefaultHepRepTypeTree::DefaultHepRepTypeTree
(
HepRepTreeID
* typeTree)
16
:
DefaultHepRepTreeID
(typeTree->getName(), typeTree->getVersion()) {
17
delete
typeTree;
18
}
19
20
DefaultHepRepTypeTree::~DefaultHepRepTypeTree
() {
21
for
(vector<HepRepType*>::iterator i1 = types.begin(); i1 != types.end(); i1++) {
22
delete
(*i1);
23
}
24
}
25
26
HepRepTypeTree
*
DefaultHepRepTypeTree::copy
() {
27
cerr <<
"DefaultHepRepTypeTree::copy() not implemented."
<< endl;
28
return
NULL;
29
}
30
31
void
DefaultHepRepTypeTree::addType
(
HepRepType
* type) {
32
// FIXME should check if type already exists
33
types.push_back(type);
34
}
35
36
vector<HepRepType*>
DefaultHepRepTypeTree::getTypeList
() {
37
return
types;
38
}
39
40
HepRepType
*
DefaultHepRepTypeTree::getType
(
string
/*typeName*/
) {
41
cerr <<
"DefaultHepRepTypeTree::getType(string) not implemented."
<< endl;
42
return
NULL;
43
}
44
45
}
// cheprep
DefaultHepRepTypeTree.h
HEPREP::HepRepTreeID
Definition:
HepRepTreeID.h:21
HEPREP::HepRepTypeTree
Definition:
HepRepTypeTree.h:26
HEPREP::HepRepType
Definition:
HepRepType.h:24
cheprep::DefaultHepRepTreeID
Definition:
DefaultHepRepTreeID.h:16
cheprep::DefaultHepRepTypeTree::copy
HEPREP::HepRepTypeTree * copy()
Definition:
DefaultHepRepTypeTree.cc:26
cheprep::DefaultHepRepTypeTree::~DefaultHepRepTypeTree
~DefaultHepRepTypeTree()
Definition:
DefaultHepRepTypeTree.cc:20
cheprep::DefaultHepRepTypeTree::getTypeList
std::vector< HEPREP::HepRepType * > getTypeList()
Definition:
DefaultHepRepTypeTree.cc:36
cheprep::DefaultHepRepTypeTree::DefaultHepRepTypeTree
DefaultHepRepTypeTree(HEPREP::HepRepTreeID *typeTree)
Definition:
DefaultHepRepTypeTree.cc:15
cheprep::DefaultHepRepTypeTree::getType
HEPREP::HepRepType * getType(std::string name)
Definition:
DefaultHepRepTypeTree.cc:40
cheprep::DefaultHepRepTypeTree::addType
void addType(HEPREP::HepRepType *type)
Definition:
DefaultHepRepTypeTree.cc:31
HEPREP
Definition:
HasHepRep.h:12
cheprep
Definition:
AbstractXMLWriter.h:12
geant4-v10.7.0
source
visualization
HepRep
src
DefaultHepRepTypeTree.cc
Generated by
1.9.6