pub enum ItemsPolicy {
Schema(NodeId),
AllowAny,
}Expand description
What an array’s elements must satisfy. Unlike AdditionalPolicy, there is no Forbid: an array
always accepts elements, only their type may be unconstrained.
Variants§
Schema(NodeId)
Every element must match this schema.
AllowAny
Any JSON value, arbitrary depth - not a regular language, so this always routes through
crate::structured.
Trait Implementations§
Source§impl<'__de, __Context> BorrowDecode<'__de, __Context> for ItemsPolicy
impl<'__de, __Context> BorrowDecode<'__de, __Context> for ItemsPolicy
Source§fn borrow_decode<__D: BorrowDecoder<'__de, Context = __Context>>(
decoder: &mut __D,
) -> Result<Self, DecodeError>
fn borrow_decode<__D: BorrowDecoder<'__de, Context = __Context>>( decoder: &mut __D, ) -> Result<Self, DecodeError>
Attempt to decode this type with the given BorrowDecode.
Source§impl Clone for ItemsPolicy
impl Clone for ItemsPolicy
Source§fn clone(&self) -> ItemsPolicy
fn clone(&self) -> ItemsPolicy
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for ItemsPolicy
Source§impl Debug for ItemsPolicy
impl Debug for ItemsPolicy
Source§impl<__Context> Decode<__Context> for ItemsPolicy
impl<__Context> Decode<__Context> for ItemsPolicy
Source§impl Encode for ItemsPolicy
impl Encode for ItemsPolicy
impl Eq for ItemsPolicy
Source§impl Hash for ItemsPolicy
impl Hash for ItemsPolicy
Source§impl PartialEq for ItemsPolicy
impl PartialEq for ItemsPolicy
impl StructuralPartialEq for ItemsPolicy
Auto Trait Implementations§
impl Freeze for ItemsPolicy
impl RefUnwindSafe for ItemsPolicy
impl Send for ItemsPolicy
impl Sync for ItemsPolicy
impl Unpin for ItemsPolicy
impl UnsafeUnpin for ItemsPolicy
impl UnwindSafe for ItemsPolicy
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