- Fragment model with validation, DTOs (immutable records), repository, service - Sidecar stdin/stdout JSON protocol for Tauri integration - DI wiring via ServiceCollectionExtensions - Scaffolded Journal.Api (not yet wired) Co-Authored-By: Warp <agent@warp.dev>
16 lines
570 B
C#
16 lines
570 B
C#
using Journal.Core.Dtos;
|
|
|
|
namespace Journal.Core.Services;
|
|
|
|
public interface IFragmentService
|
|
{
|
|
Task<FragmentDto> CreateAsync(CreateFragmentDto dto);
|
|
Task<bool> UpdateAsync(Guid id, UpdateFragmentDto dto);
|
|
Task<bool> RemoveAsync(Guid id);
|
|
Task<List<FragmentDto>> SearchAsync(string? type = null, string? tag = null, DateTimeOffset? timeAfter = null);
|
|
Task<List<FragmentDto>> GetByTagAsync(string tag);
|
|
Task<List<FragmentDto>> GetByTypeAsync(string type);
|
|
Task<List<FragmentDto>> GetAllAsync();
|
|
Task<FragmentDto?> GetByIdAsync(Guid id);
|
|
}
|