Table of Contents

Class TimeOfDayBuffer

Namespace
Balsam.Utility
Assembly
Balsam.Backtester.dll

Maintains a circular buffer of values indexed by time of day.

public class TimeOfDayBuffer
Inheritance
TimeOfDayBuffer
Inherited Members
Extension Methods

Constructors

TimeOfDayBuffer(int)

Creates a new TimeOfDayBuffer object using the specified number of periods.

public TimeOfDayBuffer(int periods)

Parameters

periods int

Properties

this[TimeSpan]

Returns the buffer for the specified key.

public IEnumerable<double> this[TimeSpan key] { get; }

Parameters

key TimeSpan

Property Value

IEnumerable<double>

Methods

Add(TimeSpan, double)

Adds a value to the buffer.

public void Add(TimeSpan key, double value)

Parameters

key TimeSpan
value double

ContainsKey(TimeSpan)

Returns true if the specified key is already present.

public bool ContainsKey(TimeSpan key)

Parameters

key TimeSpan

Returns

bool

IsFull(TimeSpan)

Returns true if the buffer is full for the specified key.

public bool IsFull(TimeSpan key)

Parameters

key TimeSpan

Returns

bool