9 #ifndef Tempus_TimeEventBase_decl_hpp
10 #define Tempus_TimeEventBase_decl_hpp
14 #include "Teuchos_VerboseObject.hpp"
16 #include "Tempus_config.hpp"
34 template<
class Scalar>
41 :
name_(
"TimeEventBase"),
42 defaultTime_ (-std::numeric_limits<Scalar>::max()*1.0e-16),
52 virtual bool isTime(Scalar time)
const
92 *out <<
"TimeEventBase name = " <<
getName() << std::endl;
119 #endif // Tempus_TimeEventBase_decl_hpp
virtual Scalar getDefaultTime() const
virtual void describe() const
Describe member data.
virtual void setName(std::string name)
virtual int indexOfNextEvent(int index) const
Index of the next event. Negative indicating the last event is in the past.
virtual bool eventInRange(Scalar time1, Scalar time2) const
Test if an event occurs within the time range.
virtual Scalar timeToNextEvent(Scalar time) const
How much time until the next event. Negative indicating the last event is in the past.
virtual bool isTime(Scalar time) const
Test if time is near a TimeEvent (within tolerance).
virtual int getDefaultIndex() const
const Scalar defaultTime_
virtual Scalar getDefaultTol() const
virtual bool isIndex(int index) const
Test if index is a time event.
virtual Scalar timeOfNextEvent(Scalar time) const
Time of the next event. Negative indicating the last event is in the past.
static RCP< FancyOStream > getDefaultOStream()
This class defines time events which can be used to "trigger" an action. Time events are points in ti...
virtual bool eventInRangeIndex(int index1, int index2) const
Test if an event occurs within the time range.
virtual std::string getName() const
virtual Scalar getAbsTol() const
virtual ~TimeEventBase()
Destructor.
virtual int indexToNextEvent(int index) const
How many indices until the next event. Negative indicating the last event is in the past...
TimeEventBase()
Constructor.