pub struct FileEpisodeStore { /* private fields */ }Expand description
JSONL ファイルベースの EpisodeStore 実装
Implementations§
Source§impl FileEpisodeStore
impl FileEpisodeStore
pub fn new(base_path: impl AsRef<Path>) -> Result<Self, StoreError>
pub fn with_cache(base_path: impl AsRef<Path>) -> Result<Self, StoreError>
Trait Implementations§
Source§impl EpisodeStore for FileEpisodeStore
impl EpisodeStore for FileEpisodeStore
Source§fn append(&self, dto: &EpisodeDto) -> Result<EpisodeId, StoreError>
fn append(&self, dto: &EpisodeDto) -> Result<EpisodeId, StoreError>
EpisodeDto を追加
Source§fn get(&self, id: &EpisodeId) -> Result<Option<EpisodeDto>, StoreError>
fn get(&self, id: &EpisodeId) -> Result<Option<EpisodeDto>, StoreError>
ID で DTO を取得
Source§fn query(&self, filter: &EpisodeFilter) -> Result<Vec<EpisodeDto>, StoreError>
fn query(&self, filter: &EpisodeFilter) -> Result<Vec<EpisodeDto>, StoreError>
フィルタで検索
Source§fn count(&self, filter: Option<&EpisodeFilter>) -> Result<usize, StoreError>
fn count(&self, filter: Option<&EpisodeFilter>) -> Result<usize, StoreError>
件数を取得
Source§fn list_meta(
&self,
filter: Option<&EpisodeFilter>,
) -> Result<Vec<EpisodeMeta>, StoreError>
fn list_meta( &self, filter: Option<&EpisodeFilter>, ) -> Result<Vec<EpisodeMeta>, StoreError>
メタ情報のみをリスト(軽量)
Auto Trait Implementations§
impl !Freeze for FileEpisodeStore
impl RefUnwindSafe for FileEpisodeStore
impl Send for FileEpisodeStore
impl Sync for FileEpisodeStore
impl Unpin for FileEpisodeStore
impl UnwindSafe for FileEpisodeStore
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more