ROL
ROL_ScalarController_Def.hpp
Go to the documentation of this file.
1// @HEADER
2// *****************************************************************************
3// Rapid Optimization Library (ROL) Package
4//
5// Copyright 2014 NTESS and the ROL contributors.
6// SPDX-License-Identifier: BSD-3-Clause
7// *****************************************************************************
8// @HEADER
9
10#ifndef ROL_SCALARCONTROLLER_DEF_H
11#define ROL_SCALARCONTROLLER_DEF_H
12
13namespace ROL {
14
15template <class Real, class Key>
17
18template <class Real, class Key>
19bool ScalarController<Real,Key>::get(Real &x, const Key &param) {
20 SingletonVector<Real> xv(Real(0));
21 bool flag = VectorController<Real,Key>::get(xv,param);
22 x = xv.getValue();
23 return flag;
24}
25
26template <class Real, class Key>
27void ScalarController<Real,Key>::set(Real x, const Key &param) {
30}
31
32} // namespace ROL
33
34#endif
void set(Real x, const Key &param)
bool get(Real &x, const Key &param)
const Ptr< Vector< Real > > set(const Key &param)
Set the vector associated with provided key. This assumes the vector data will be changed.
const Ptr< const Vector< Real > > get(const Key &param) const
Return the vector associated with provided key.