pub enum OutputFormat<T = String> {
Jsonl,
Url,
Other(T),
}Expand description
An output format for a listing.
The standard command-line names are jsonl and url. Other names are
parsed through T, which defaults to String to accept arbitrary names.
Use an enum implementing FromStr to restrict custom formats.
Display delegates custom format names to T.
The default is Jsonl. An unset
crate::ListerOptions::output still omits the option entirely.
Variants§
Implementations§
Trait Implementations§
Source§impl<T: Clone> Clone for OutputFormat<T>
impl<T: Clone> Clone for OutputFormat<T>
impl<T: Copy> Copy for OutputFormat<T>
Source§impl<T: Debug> Debug for OutputFormat<T>
impl<T: Debug> Debug for OutputFormat<T>
Source§impl<T> Default for OutputFormat<T>
impl<T> Default for OutputFormat<T>
Source§impl<T: Display> Display for OutputFormat<T>
impl<T: Display> Display for OutputFormat<T>
impl<T: Eq> Eq for OutputFormat<T>
Source§impl<T: FromStr> FromStr for OutputFormat<T>
impl<T: FromStr> FromStr for OutputFormat<T>
Source§impl<T: Hash> Hash for OutputFormat<T>
impl<T: Hash> Hash for OutputFormat<T>
Source§impl<T: Ord> Ord for OutputFormat<T>
impl<T: Ord> Ord for OutputFormat<T>
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl<T: PartialEq> PartialEq for OutputFormat<T>
impl<T: PartialEq> PartialEq for OutputFormat<T>
Source§impl<T: PartialOrd> PartialOrd for OutputFormat<T>
impl<T: PartialOrd> PartialOrd for OutputFormat<T>
impl<T: PartialEq> StructuralPartialEq for OutputFormat<T>
Auto Trait Implementations§
impl<T> Freeze for OutputFormat<T>where
T: Freeze,
impl<T> RefUnwindSafe for OutputFormat<T>where
T: RefUnwindSafe,
impl<T> Send for OutputFormat<T>where
T: Send,
impl<T> Sync for OutputFormat<T>where
T: Sync,
impl<T> Unpin for OutputFormat<T>where
T: Unpin,
impl<T> UnsafeUnpin for OutputFormat<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for OutputFormat<T>where
T: UnwindSafe,
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