17 lines
557 B
C#
17 lines
557 B
C#
using System.Collections.Generic;
|
|
using System.Threading.Tasks;
|
|
using Website.Models;
|
|
|
|
namespace Website.Data {
|
|
public interface IBlogApi {
|
|
Task<BlogPost> GetPostByUrlAsync(string url);
|
|
Task<IEnumerable<BlogPost>> GetLatestPostsAsync(int count = 0, int offset = 0);
|
|
Task<BlogPost> GetLatestPostAsync();
|
|
Task<int> GetCountAsync();
|
|
Task<BlogPost> GetPostByIdAsync(int id);
|
|
Task<BlogPost> SavePost(BlogPostSubmission post);
|
|
Task<IEnumerable<BlogPost>> GetAllPostsAsync();
|
|
Task DeletePostAsync(int id);
|
|
Task PublishPostAsync(int id);
|
|
}
|
|
}
|