Class ResourceProviderActionResult<T>
- Namespace
- FoundationaLLM.Common.Models.ResourceProviders
- Assembly
- FoundationaLLM.Common.dll
The result of an action executed by a resource provider.
public record ResourceProviderActionResult<T> : ResourceProviderActionResult, IEquatable<ResourceProviderActionResult>, IEquatable<ResourceProviderActionResult<T>> where T : ResourceBase
Type Parameters
T
- Inheritance
-
ResourceProviderActionResult<T>
- Implements
- Inherited Members
- Extension Methods
Constructors
ResourceProviderActionResult(string, bool, string?)
The result of an action executed by a resource provider.
public ResourceProviderActionResult(string ObjectId, bool IsSuccessResult, string? ErrorMessage = null)
Parameters
ObjectId
stringThe object id to which the result refers to.
IsSuccessResult
boolIndicates whether the action executed successfully or not.
ErrorMessage
stringWhen IsSuccess is false, contains an error message with details.
Properties
IsSuccessResult
Indicates whether the action executed successfully or not.
public bool IsSuccessResult { get; init; }
Property Value
Resource
Gets or sets the resource resulting from the action.
[JsonPropertyName("resource")]
public T? Resource { get; set; }
Property Value
- T
Remarks
Each resource provider will decide whether to return the resource in the action result or not.