import { Result } from "@webiny/feature/api"; import type { CmsEntry, CmsEntryValues, CmsModel } from "../../../types/index.js"; import { EntryNotFoundError, type EntryPersistenceError } from "../../../domain/contentEntry/errors.js"; /** * GetPublishedRevisionByEntryId Use Case */ export interface IGetPublishedRevisionByEntryIdUseCase { execute(model: CmsModel, entryId: string): Promise | null, UseCaseError>>; } export interface IGetPublishedRevisionByEntryIdUseCaseErrors { repository: RepositoryError; } type UseCaseError = IGetPublishedRevisionByEntryIdUseCaseErrors[keyof IGetPublishedRevisionByEntryIdUseCaseErrors]; /** Retrieve the published revision of an entry. */ export declare const GetPublishedRevisionByEntryIdUseCase: import("@webiny/di").Abstraction; export declare namespace GetPublishedRevisionByEntryIdUseCase { type Interface = IGetPublishedRevisionByEntryIdUseCase; type Error = UseCaseError; type Return = Promise | null, UseCaseError>>; } /** * GetPublishedRevisionByEntryIdRepository - Fetches published revision from storage. */ export interface IGetPublishedRevisionByEntryIdRepository { execute(model: CmsModel, entryId: string): Promise | null, RepositoryError>>; } export interface IGetPublishedRevisionByEntryIdRepositoryErrors { storage: EntryPersistenceError; notFound: EntryNotFoundError; } type RepositoryError = IGetPublishedRevisionByEntryIdRepositoryErrors[keyof IGetPublishedRevisionByEntryIdRepositoryErrors]; export declare const GetPublishedRevisionByEntryIdRepository: import("@webiny/di").Abstraction; export declare namespace GetPublishedRevisionByEntryIdRepository { type Interface = IGetPublishedRevisionByEntryIdRepository; type Error = RepositoryError; } export {};