ATLAS Offline Software
Loading...
Searching...
No Matches
HWIdentifier.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5//<doc><file> $Id: HWIdentifier.h,v 1.3 2004-02-24 13:52:15 schaffer Exp $
6//<version> $Name: not supported by cvs2svn $
7
8#ifndef IDENTIFIER_HWIDENTIFIER_H
9# define IDENTIFIER_HWIDENTIFIER_H
10
11#include "Identifier/Identifier.h"
12
13class HWIdentifier : public Identifier {
14
15public:
16
18 HWIdentifier() = default;
19
21 explicit HWIdentifier(value_type value);
22
24 explicit HWIdentifier(const Identifier& old);
25
28 explicit HWIdentifier(int value);
29};
30
31
32// Define a hash functional
33
34namespace std {
35template<>
36struct hash<HWIdentifier>
37{
38 size_t operator()(const HWIdentifier& id) const
39 {
40 return static_cast<size_t>(id.get_compact());
41 }
42};
43}
44
48
52
56
58 : Identifier::Identifier(value)
59{}
60
61#endif // IDENTIFIER_HWIDENTIFIER_H
HWIdentifier()=default
Default constructor.
unsigned int value_type
STL namespace.
size_t operator()(const HWIdentifier &id) const