pub enum RecordFormat {
Fixed,
RDW,
}Expand description
Record format specification
Controls whether records have a fixed byte length (LRECL) or use variable-length RDW (Record Descriptor Word) framing.
§Examples
use copybook_options::RecordFormat;
let fmt = RecordFormat::Fixed;
assert!(fmt.is_fixed());
assert!(!fmt.is_variable());
assert_eq!(fmt.description(), "Fixed-length records");Variants§
Implementations§
Source§impl RecordFormat
impl RecordFormat
Sourcepub const fn is_variable(self) -> bool
pub const fn is_variable(self) -> bool
Check if this is a variable-length record format
Sourcepub const fn description(self) -> &'static str
pub const fn description(self) -> &'static str
Get a human-readable description of the format
Trait Implementations§
Source§impl Clone for RecordFormat
impl Clone for RecordFormat
Source§fn clone(&self) -> RecordFormat
fn clone(&self) -> RecordFormat
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 RecordFormat
impl Debug for RecordFormat
Source§impl<'de> Deserialize<'de> for RecordFormat
impl<'de> Deserialize<'de> for RecordFormat
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<RecordFormat, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<RecordFormat, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for RecordFormat
impl Display for RecordFormat
Source§impl PartialEq for RecordFormat
impl PartialEq for RecordFormat
Source§impl Serialize for RecordFormat
impl Serialize for RecordFormat
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Source§impl ValueEnum for RecordFormat
impl ValueEnum for RecordFormat
Source§fn value_variants<'a>() -> &'a [RecordFormat]
fn value_variants<'a>() -> &'a [RecordFormat]
All possible argument values, in display order.
Source§fn to_possible_value<'a>(&self) -> Option<PossibleValue>
fn to_possible_value<'a>(&self) -> Option<PossibleValue>
The canonical argument value. Read more
impl Copy for RecordFormat
impl Eq for RecordFormat
impl StructuralPartialEq for RecordFormat
Auto Trait Implementations§
impl Freeze for RecordFormat
impl RefUnwindSafe for RecordFormat
impl Send for RecordFormat
impl Sync for RecordFormat
impl Unpin for RecordFormat
impl UnsafeUnpin for RecordFormat
impl UnwindSafe for RecordFormat
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.