TBTK
Density.h
Go to the documentation of this file.
1 /* Copyright 2016 Kristofer Björnson
2  *
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
23 #ifndef COM_DAFER45_TBTK_DENSITY
24 #define COM_DAFER45_TBTK_DENSITY
25 
26 namespace TBTK{
27  class CPropertyExtractor;
28  class DPropertyExtractor;
29  class FileReader;
30 namespace Property{
31 
33 class Density{
34 public:
36  Density(int dimensions, const int *ranges);
37 
39  ~Density();
40 
42  int getDimensions() const;
43 
45  const int* getRanges() const;
46 
48  int getSize() const;
49 
51  const double* getData() const;
52 private:
54  int dimensions;
55 
57  int *ranges;
58 
60  int size;
61 
63  double *data;
64 
68 
72 
74  friend class TBTK::FileReader;
75 };
76 
77 inline int Density::getDimensions() const{
78  return dimensions;
79 }
80 
81 inline const int* Density::getRanges() const{
82  return ranges;
83 }
84 
85 inline int Density::getSize() const{
86  return size;
87 }
88 
89 inline const double* Density::getData() const{
90  return data;
91 }
92 
93 }; //End namespace Property
94 }; //End namespace TBTK
95 
96 #endif
Definition: CPropertyExtractor.h:37
Density(int dimensions, const int *ranges)
Definition: Density.cpp:26
Definition: FileReader.h:46
const int * getRanges() const
Definition: Density.h:81
int getSize() const
Definition: Density.h:85
Definition: AbstractOperator.h:26
Definition: DPropertyExtractor.h:40
Definition: Density.h:33
const double * getData() const
Definition: Density.h:89
~Density()
Definition: Density.cpp:41
int getDimensions() const
Definition: Density.h:77