Click or drag to resize

CachingMotionEvaluatorT Class

A wrapper for any MotionEvaluatorT that caches the last evaluated result. This way, if a second evaluation is requested for the same date, the value is returned without recomputing it. This class is intended to be returned by GetCachingWrapper.
Inheritance Hierarchy
SystemObject
  AGI.FoundationFunctionJulianDate, T
    AGI.FoundationMotionEvaluatorT
      AGI.Foundation.InfrastructureCachingMotionEvaluatorT

Namespace:  AGI.Foundation.Infrastructure
Assembly:  AGI.Foundation.Core (in AGI.Foundation.Core.dll) Version: 24.3.420.0 (24.3.420.0)
Syntax
public sealed class CachingMotionEvaluator<T> : MotionEvaluator<T>, 
	ICachingEvaluator, IEvaluator, IAvailability, IThreadAware, ICloneWithContext, 
	IDisposable

Type Parameters

T
The type of motion returned by evaluation.

The CachingMotionEvaluatorT type exposes the following members.

Constructors
Properties
  NameDescription
Public propertyAvailabilityIntervals
Gets a TimeIntervalCollection over which data is available. If the availability interval is infinite, this returns Infinite.
(Inherited from MotionEvaluatorT.)
Public propertyGroup
Gets the group that contains this evaluator.
(Inherited from MotionEvaluatorT.)
Public propertyIsThreadSafe
Gets a value indicating whether the methods on this instance are safe to call from multiple threads simultaneously.
(Overrides FunctionTIndependent, TDependentIsThreadSafe.)
Public propertyIsTimeVarying
Gets a value indicating whether or not the value of this evaluator changes with time. If , the evaluator is assumed to return the same value for any input JulianDate.
(Overrides MotionEvaluatorTIsTimeVarying.)
Top
Methods
  NameDescription
Public methodClearCache
Clears any values cached by this evaluator.
Public methodClone
Clones this object using the specified context.
(Overrides FunctionTIndependent, TDependentClone(CopyContext).)
Public methodDispose
Releases any resources associated with this instance.
(Inherited from FunctionTIndependent, TDependent.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodEvaluate(JulianDate)
Evaluates the function.
(Overrides MotionEvaluatorTEvaluate(JulianDate).)
Public methodEvaluate(JulianDate, Int32)
Evaluates the function, first checking for a cached result corresponding to date and order.
(Overrides MotionEvaluatorTEvaluate(JulianDate, Int32).)
Public methodEvaluate(TimeInterval, Duration, Int32)
Evaluates this evaluator at a specified fixed step over the specified interval.
(Inherited from MotionEvaluatorT.)
Public methodEvaluate(JulianDate, JulianDate, Duration, Int32)
Evaluates this evaluator at a specified fixed step over the specified interval.
(Inherited from MotionEvaluatorT.)
Public methodEvaluate(TimeInterval, Duration, Int32, ITrackCalculationProgress)
Evaluates this evaluator at a specified fixed step over the specified interval.
(Inherited from MotionEvaluatorT.)
Public methodEvaluate(JulianDate, JulianDate, Duration, Int32, ITrackCalculationProgress)
Evaluates this evaluator at a specified fixed step over the specified interval.
(Inherited from MotionEvaluatorT.)
Public methodGetAvailabilityIntervals
Gets the intervals over which data is available.
(Overrides MotionEvaluatorTGetAvailabilityIntervals(TimeIntervalCollection).)
Public methodGetCachingWrapper
Gets a version of this evaluator that caches the previously computed value so that if it is evaluated twice at the same date the computation is done only once.
(Overrides MotionEvaluatorTGetCachingWrapper.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetNextSampleSuggestion
Gets a suggestion for the next JulianDate value at which to sample this function.
(Overrides FunctionTIndependent, TDependentGetNextSampleSuggestion(TIndependent).)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodIsAvailable
Determines if valid data is available for the given JulianDate.
(Overrides MotionEvaluatorTIsAvailable(JulianDate).)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodCode exampleUpdateEvaluatorReferences
Updates the evaluator references held by this object using the reference-to-reference mapping in the specified CopyContext.
(Overrides MotionEvaluatorTUpdateEvaluatorReferences(CopyContext).)
Top
See Also