Skip to main content

ContractBuilder

Struct ContractBuilder 

Source
pub struct ContractBuilder<S: State = Empty> { /* private fields */ }
Expand description

Use builder syntax to set the inputs and finish with build().

Implementations§

Source§

impl<S: State> ContractBuilder<S>

Source

pub fn build(self) -> Contract
where S: IsComplete,

Finish building and return the requested object

Source

pub fn capacity(self, value: CapacityPlan) -> ContractBuilder<SetCapacity<S>>
where S::Capacity: IsUnset,

Required.

Capacity posture staff and automation must honor before confirming stays.

Source

pub fn arrival_window( self, value: ServiceWindow, ) -> ContractBuilder<SetArrivalWindow<S>>
where S::ArrivalWindow: IsUnset,

Required.

Guest arrival window used for front-desk staffing and check-in promises.

Source

pub fn departure_window( self, value: ServiceWindow, ) -> ContractBuilder<SetDepartureWindow<S>>
where S::DepartureWindow: IsUnset,

Required.

Guest departure window used for checkout staffing and Pawgress/report timing.

Source

pub fn minimum_stay(self, value: Policy) -> ContractBuilder<SetMinimumStay<S>>
where S::MinimumStay: IsUnset,

Required.

Minimum-stay rule for standard, holiday, or multi-pet boarding demand.

Source

pub fn cancellation(self, value: Policy) -> ContractBuilder<SetCancellation<S>>
where S::Cancellation: IsUnset,

Required.

Cancellation policy that governs notice, deposit forfeiture, and manager review.

Source

pub fn deposit(self, value: DepositRule) -> ContractBuilder<SetDeposit<S>>
where S::Deposit: IsUnset,

Required.

Deposit requirement used before staff or automation treats the booking as secured.

Source

pub fn payment(self, value: PaymentTiming) -> ContractBuilder<SetPayment<S>>
where S::Payment: IsUnset,

Required.

Payment timing that constrains collection workflow and front-desk labor.

Source

pub fn housekeeping(self, value: Cadence) -> ContractBuilder<SetHousekeeping<S>>
where S::Housekeeping: IsUnset,

Required.

Room-cleaning cadence that feeds labor planning for the stay.

Source

pub fn handoff(self, value: Requirement) -> ContractBuilder<SetHandoff<S>>
where S::Handoff: IsUnset,

Required.

Staff handoff checklist required at arrival, medication review, or departure.

Source

pub fn upsells(self, value: Vec<Upsell>) -> ContractBuilder<SetUpsells<S>>
where S::Upsells: IsUnset,

Optional (Some / Option setters). Default: <Vec<Upsell> as Default>::default().

Optional services that can be offered only through the review-gated recommendation flow.

Source

pub fn maybe_upsells( self, value: Option<Vec<Upsell>>, ) -> ContractBuilder<SetUpsells<S>>
where S::Upsells: IsUnset,

Optional (Some / Option setters). Default: <Vec<Upsell> as Default>::default().

Optional services that can be offered only through the review-gated recommendation flow.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.