//
//  ReferenceManager.h
//  Pods
//
//  Created by Ran Zhao on 9/2/24.
//

#ifndef ReferenceManager_h
#define ReferenceManager_h

#import <Foundation/Foundation.h>
#import "Reference.h"

@interface ReferenceManager : NSObject

@property (nonatomic, strong) NSMutableArray<Reference *> *refList;
@property (nonatomic, strong) Reference *curReference;
@property (nonatomic, strong) Reference *mCurrentReference;
@property (nonatomic, assign) int kCount;

- (instancetype)init;
- (Reference *)getRefValue;
- (void)addCurrentReference:(double)value index:(NSInteger)index;
- (void)addReference:(double)value time:(NSDate *)time;
- (BOOL)isCalK;
- (BOOL)isWaitCalK;
- (Reference *)findReferenceByDate:(NSDate *)curTime;
- (Reference *)findReferenceByIndex:(NSInteger)index;
+ (NSDate *)stringToDate:(NSString *)dateStr;

@end

#endif /* ReferenceManager_h */
