mirror of
https://github.com/nomic-ai/gpt4all.git
synced 2024-10-01 01:06:10 -04:00
21 lines
478 B
C#
21 lines
478 B
C#
|
namespace Gpt4All.LibraryLoader;
|
||
|
|
||
|
public class LoadResult
|
||
|
{
|
||
|
private LoadResult(bool isSuccess, string? errorMessage)
|
||
|
{
|
||
|
IsSuccess = isSuccess;
|
||
|
ErrorMessage = errorMessage;
|
||
|
}
|
||
|
|
||
|
public static LoadResult Success { get; } = new(true, null);
|
||
|
|
||
|
public static LoadResult Failure(string errorMessage)
|
||
|
{
|
||
|
return new(false, errorMessage);
|
||
|
}
|
||
|
|
||
|
public bool IsSuccess { get; }
|
||
|
public string? ErrorMessage { get; }
|
||
|
}
|