Refactor Implementations.cs to use enums, backwards compat to GetAi(string name)

This commit is contained in:
N00MKRAD
2024-08-21 14:45:46 +02:00
parent 0b500563ca
commit 713c64e6ec
18 changed files with 120 additions and 92 deletions

View File

@@ -9,12 +9,12 @@ namespace Flowframes.Data
{
public class ModelCollection
{
public AI Ai { get; set; } = null;
public AiInfo Ai { get; set; } = null;
public List<ModelInfo> Models { get; set; } = new List<ModelInfo>();
public class ModelInfo
{
public AI Ai { get; set; } = null;
public AiInfo Ai { get; set; } = null;
public string Name { get; set; } = "";
public string Desc { get; set; } = "";
public string Dir { get; set; } = "";
@@ -36,12 +36,12 @@ namespace Flowframes.Data
}
}
public ModelCollection(AI ai)
public ModelCollection(AiInfo ai)
{
Ai = ai;
}
public ModelCollection(AI ai, string jsonContentOrPath)
public ModelCollection(AiInfo ai, string jsonContentOrPath)
{
Ai = ai;