OPAL (Object Oriented Parallel Accelerator Library) 2022.1
OPAL
RealVector.h
Go to the documentation of this file.
1//
2// Class RealVector
3// The REAL VECTOR definition.
4//
5// Copyright (c) 2000 - 2021, Paul Scherrer Institut, Villigen PSI, Switzerland
6// All rights reserved
7//
8// This file is part of OPAL.
9//
10// OPAL is free software: you can redistribute it and/or modify
11// it under the terms of the GNU General Public License as published by
12// the Free Software Foundation, either version 3 of the License, or
13// (at your option) any later version.
14//
15// You should have received a copy of the GNU General Public License
16// along with OPAL. If not, see <https://www.gnu.org/licenses/>.
17//
18#ifndef OPAL_RealVector_HH
19#define OPAL_RealVector_HH
20
22
23
25
26public:
27
29 RealVector();
30
31 virtual ~RealVector();
32
34 // True, if [b]rhs[/b] is a real vector.
35 virtual bool canReplaceBy(Object *rhs);
36
38 virtual RealVector *clone(const std::string &name);
39
41 virtual void print(std::ostream &) const;
42
44 virtual void printValue(std::ostream &os) const;
45
47 virtual double getRealComponent(int) const;
48
49private:
50
51 // Not implemented.
53 void operator=(const RealVector &);
54
55 // Clone constructor.
56 RealVector(const std::string &name, RealVector *parent);
57};
58
59#endif // OPAL_RealVector_HH
const std::string name
The base class for all OPAL objects.
Definition: Object.h:48
The base class for all OPAL value definitions.
virtual bool canReplaceBy(Object *rhs)
Test for allowed replacement.
Definition: RealVector.cpp:47
virtual double getRealComponent(int) const
Return indexed value.
Definition: RealVector.cpp:68
RealVector(const RealVector &)
void operator=(const RealVector &)
virtual RealVector * clone(const std::string &name)
Make clone.
Definition: RealVector.cpp:53
virtual ~RealVector()
Definition: RealVector.cpp:43
virtual void print(std::ostream &) const
Print the vector.
Definition: RealVector.cpp:58
RealVector()
Exemplar constructor.
Definition: RealVector.cpp:27
virtual void printValue(std::ostream &os) const
Print its value.
Definition: RealVector.cpp:64