From 5f60208516801d466c8683a83e35c4af301c28d5 Mon Sep 17 00:00:00 2001 From: wolf Date: Mon, 22 Feb 1999 14:51:38 +0000 Subject: [PATCH] Make the function time usable again: remove the #time# variable from the Function class. Clean FunctionTime a bit. git-svn-id: https://svn.dealii.org/trunk@874 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/base/include/base/function.h | 9 +-------- deal.II/base/include/base/function_time.h | 12 +++++++----- 2 files changed, 8 insertions(+), 13 deletions(-) diff --git a/deal.II/base/include/base/function.h b/deal.II/base/include/base/function.h index e3a6acde4b..48ddc05c26 100644 --- a/deal.II/base/include/base/function.h +++ b/deal.II/base/include/base/function.h @@ -40,8 +40,7 @@ * @author Wolfgang Bangerth, 1998, 1999 */ template -class Function : - public FunctionTime +class Function : public FunctionTime { public: /** @@ -101,12 +100,6 @@ class Function : int, int, << "The vector has size " << arg1 << " but should have " << arg2 << " elements."); - - protected: - /** - * Store the present time. - */ - double time; }; diff --git a/deal.II/base/include/base/function_time.h b/deal.II/base/include/base/function_time.h index d29dc463a2..21cb151f14 100644 --- a/deal.II/base/include/base/function_time.h +++ b/deal.II/base/include/base/function_time.h @@ -59,10 +59,10 @@ class FunctionTime { */ FunctionTime (const double initial_time = 0.0); - /** - * Virtual destructor. - */ - virtual ~FunctionTime(); + /** + * Virtual destructor. + */ + virtual ~FunctionTime(); /** * Return the value of the time variable/ @@ -81,13 +81,15 @@ class FunctionTime { */ virtual void advance_time (const double delta_t); -private: + private: /** * Store the present time. */ double time; }; + + inline double FunctionTime::get_time () const { -- 2.39.5