source: trunk/src/NearestInterpolator1D.h @ 3048

Last change on this file since 3048 was 2733, checked in by Takeshi Nakazato, 11 years ago

New Development: No

JIRA Issue: Yes CAS-4770

Ready for Test: Yes

Interface Changes: Yes/No?

What Interface Changed: Please list interface changes

Test Programs: List test programs

Put in Release Notes: Yes/No?

Module(s): Module Names change impacts.

Description: Describe your changes here...

Redefined Interpolator1D and derived classes as template class.


File size: 1.1 KB
RevLine 
[2720]1//
2// C++ Interface: NearestInterpolator1D
3//
4// Description:
5//
6//
7// Author: Takeshi Nakazato <takeshi.nakazato@nao.ac.jp>, (C) 2012
8//
9// Copyright: See COPYING file that comes with this distribution
10//
11//
12#ifndef ASAP_NEAREST_INTERPOLATOR_1D_H
13#define ASAP_NEAREST_INTERPOLATOR_1D_H
14
15#include <memory>
16#include <vector>
17
18#include <casa/aips.h>
19#include <casa/Containers/Block.h>
20#include <casa/Arrays/Vector.h>
21#include <casa/Arrays/Matrix.h>
22#include <casa/BasicSL/String.h>
23#include <casa/Utilities/CountedPtr.h>
24
25#include "Interpolator1D.h"
26
27namespace asap {
28
29/**
[2730]30 * Implementation of nearest interpolation.
[2720]31 * @author TakeshiNakazato
32 */
[2733]33template <class T, class U>
34class NearestInterpolator1D : public Interpolator1D<T, U> {
[2720]35public:
[2730]36  // Default constructor.
[2720]37  NearestInterpolator1D();
38
[2730]39  // Destructor.
[2720]40  virtual ~NearestInterpolator1D();
41
[2730]42  // Perform interpolation.
43  // @param[in] x horizontal location where the value is evaluated
44  //              by interpolation.
45  // @return interpolated value at x.
46  // @see Interpolator1D::interpolate()
[2733]47  U interpolate(T x);
[2720]48};
49
50}
[2733]51
52#include "NearestInterpolator1D.tcc"
53
[2720]54#endif
Note: See TracBrowser for help on using the repository browser.