pub struct LocationCreationWrapper { /* private fields */ }Expand description
Build a wrapping a Location
When passing a Location to one of the request methods, they almost always must be wrapped within a LocationCreationWrapper to adhere to the Square API contract.
A Location must have a name upon creation, otherwise it is not seen as a valid new Location.
.name()
§Example: Build a LocationCreationWrapper
use square_ox::{
builder::Builder,
api::locations::LocationCreationWrapper,
};
async {
let builder = Builder::from(LocationCreationWrapper::default())
.name("The Foo Bar".to_string())
.build()
.await;
};Trait Implementations§
Source§impl Clone for LocationCreationWrapper
impl Clone for LocationCreationWrapper
Source§fn clone(&self) -> LocationCreationWrapper
fn clone(&self) -> LocationCreationWrapper
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LocationCreationWrapper
impl Debug for LocationCreationWrapper
Source§impl Default for LocationCreationWrapper
impl Default for LocationCreationWrapper
Source§fn default() -> LocationCreationWrapper
fn default() -> LocationCreationWrapper
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for LocationCreationWrapper
impl<'de> Deserialize<'de> for LocationCreationWrapper
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for LocationCreationWrapper
impl Serialize for LocationCreationWrapper
Source§impl Validate for LocationCreationWrapper
impl Validate for LocationCreationWrapper
Auto Trait Implementations§
impl Freeze for LocationCreationWrapper
impl RefUnwindSafe for LocationCreationWrapper
impl Send for LocationCreationWrapper
impl Sync for LocationCreationWrapper
impl Unpin for LocationCreationWrapper
impl UnwindSafe for LocationCreationWrapper
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