2021-03-28 22:50:55 +00:00
|
|
|
//
|
|
|
|
// SoftwareList.h
|
|
|
|
// Ample
|
|
|
|
//
|
|
|
|
// Created by Kelvin Sherlock on 3/28/2021.
|
|
|
|
// Copyright © 2021 Kelvin Sherlock. All rights reserved.
|
|
|
|
//
|
|
|
|
|
|
|
|
#ifndef SoftwareList_h
|
|
|
|
#define SoftwareList_h
|
|
|
|
|
|
|
|
#import <Foundation/Foundation.h>
|
2021-05-27 23:42:28 +00:00
|
|
|
#import "AutocompleteControl.h"
|
2021-03-28 22:50:55 +00:00
|
|
|
|
2021-05-27 23:42:28 +00:00
|
|
|
|
|
|
|
@interface SoftwareList : NSObject <AutocompleteItem>
|
2021-03-28 22:50:55 +00:00
|
|
|
@property NSString *name;
|
|
|
|
@property NSString *title;
|
|
|
|
@property NSArray *items;
|
2021-10-07 01:05:58 +00:00
|
|
|
@property NSString *notes;
|
2021-05-27 23:42:28 +00:00
|
|
|
|
|
|
|
-(SoftwareList *)filter: (NSString *)filter;
|
|
|
|
|
2021-03-28 22:50:55 +00:00
|
|
|
@end
|
|
|
|
|
2021-05-27 23:42:28 +00:00
|
|
|
@interface Software : NSObject <AutocompleteItem>
|
2021-03-28 22:50:55 +00:00
|
|
|
@property NSString *name;
|
|
|
|
@property NSString *title;
|
2021-05-27 23:42:28 +00:00
|
|
|
@property NSString *compatibility;
|
|
|
|
@property NSString *list;
|
2021-10-07 01:05:58 +00:00
|
|
|
@property NSString *notes;
|
2021-05-27 23:42:28 +00:00
|
|
|
|
|
|
|
-(NSString *)fullName;
|
|
|
|
|
2022-02-27 02:21:27 +00:00
|
|
|
@property NSString *searchTitle;
|
|
|
|
|
2021-05-27 23:42:28 +00:00
|
|
|
@end
|
|
|
|
|
|
|
|
@interface SoftwareSet : NSObject <NSFastEnumeration, AutoCompleteDelegate>
|
|
|
|
|
|
|
|
+(instancetype)softwareSetForMachine: (NSString *)machine;
|
2022-04-30 14:17:57 +00:00
|
|
|
+(void)invalidate;
|
|
|
|
|
2021-05-27 23:42:28 +00:00
|
|
|
-(BOOL)nameIsUnique: (NSString *)name;
|
|
|
|
|
2021-06-07 04:34:26 +00:00
|
|
|
-(NSString *)nameForSoftware: (Software *)software;
|
|
|
|
-(Software *)softwareForName: (NSString *)name;
|
|
|
|
|
|
|
|
-(BOOL)hasSoftware: (Software *)software;
|
2021-03-28 22:50:55 +00:00
|
|
|
@end
|
|
|
|
|
|
|
|
|
2021-05-27 23:42:28 +00:00
|
|
|
//NSArray<SoftwareList *> *SoftwareListForMachine(NSString *machine);
|
2021-03-28 22:50:55 +00:00
|
|
|
|
|
|
|
|
|
|
|
#endif /* SoftwareList_h */
|