Interface IAddToRelationshipService<TResource, TId>
- Namespace
- JsonApiDotNetCore.Services
- Assembly
- JsonApiDotNetCore.dll
[PublicAPI]
public interface IAddToRelationshipService<TResource, in TId> where TResource : class, IIdentifiable<in TId>
Type Parameters
TResourceTId
Methods
AddToToManyRelationshipAsync(TId, string, ISet<IIdentifiable>, CancellationToken)
Handles a JSON:API request to add resources to a to-many relationship.
Task AddToToManyRelationshipAsync(TId leftId, string relationshipName, ISet<IIdentifiable> rightResourceIds, CancellationToken cancellationToken)
Parameters
leftIdTIdIdentifies the left side of the relationship.
relationshipNamestringThe relationship to add resources to.
rightResourceIdsISet<IIdentifiable>The set of resources to add to the relationship.
cancellationTokenCancellationTokenPropagates notification that request handling should be canceled.