pub fn required(
        name: &str,
        help: &str,
        short_name: Option<char>,
        default_value: Option<&str>,
    ) -> Spec {
        Spec {
            name: name.to_owned(),
            help: help.to_owned(),
            short_name: short_name,
            flag_type: Type::Required {
                default_value: default_value.map(|dv| dv.to_owned()),
            },
        }
    }
/// Constructs a Spec which describes a required named flag. This flag may
/// have a default value, but the key point is that it must have some value
/// after parsing is complete.
Constructs a Spec which describes a required named flag. This flag may
have a default value, but the key point is that it must have some value
after parsing is complete.
Constructs a Spec which describes a required named flag . This flag may have a default value but the key point is that it must have some value after parsing is complete .
pub fn required(
        name: &str,
        help: &str,
        short_name: Option<char>,
        default_value: Option<&str>,
    ) -> Spec {
        Spec {
            name: name.to_owned(),
            help: help.to_owned(),
            short_name: short_name,
            flag_type: Type::Required {
                default_value: default_value.map(|dv| dv.to_owned()),
            },
        }
    }
pub fn required ( name : & str , help : & str , short_name : Option < char > , default_value : Option < & str > , ) -> Spec { Spec { name : name . to_owned ( ) , help : help . to_owned ( ) , short_name : short_name , flag_type : Type :: Required { default_value : default_value . map ( | dv | dv . to_owned ( ) ) , } , } }
Constructs a Spec which describes a required named flag.
Constructs a Spec which describes a required named flag .
name
&str
help
&str
short_name
Option<char>
default_value
Option<&str>
name
&str
help
&str
short_name
Option<char>
default_value
Option<&str>