pub struct CmsPage {
pub id: PageId,
pub locale: LocaleCode,
pub current_revision: PageRevision,
/* private fields */
}Fields§
§id: PageId§locale: LocaleCode§current_revision: PageRevisionImplementations§
Source§impl CmsPage
impl CmsPage
pub fn new( id: PageId, locale: LocaleCode, initial_revision: PageRevision, ) -> Self
pub fn publication(&self) -> &PublicationState
pub fn workflow_status(&self) -> PageWorkflowStatus
pub fn preview_revision(&self) -> &PageRevision
pub fn live_revision(&self) -> Result<&PageRevision, CmsModelError>
pub fn replace_draft(&mut self, revision: PageRevision)
pub fn publish_current(&mut self)
pub fn schedule_current( &mut self, publish_at: u64, now: u64, ) -> Result<(), CmsModelError>
pub fn apply_schedule(&mut self, now: u64) -> bool
pub fn unpublish(&mut self) -> Result<(), CmsModelError>
pub fn live_path(&self) -> Result<String, CmsModelError>
pub fn preview_path(&self) -> String
pub fn save_draft_transaction_plan( &self, ) -> Result<TransactionPlan, CmsModelError>
pub fn publish_transaction_plan(&self) -> Result<TransactionPlan, CmsModelError>
pub fn schedule_transaction_plan( &self, ) -> Result<TransactionPlan, CmsModelError>
pub fn unpublish_transaction_plan( &self, ) -> Result<TransactionPlan, CmsModelError>
Trait Implementations§
impl Eq for CmsPage
impl StructuralPartialEq for CmsPage
Auto Trait Implementations§
impl Freeze for CmsPage
impl RefUnwindSafe for CmsPage
impl Send for CmsPage
impl Sync for CmsPage
impl Unpin for CmsPage
impl UnsafeUnpin for CmsPage
impl UnwindSafe for CmsPage
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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