(self, name: 'OptionKey', value: T.Optional[T.Any], prefix: str)
return self.opt_type(self.description, **keywords)
Create an instance of opt_type and return it.
Create an instance of opt_type and return it.
Create an instance of opt_type and return it .
def init_option(self, name: 'OptionKey', value: T.Optional[T.Any], prefix: str) -> _U:
        """Create an instance of opt_type and return it."""
        if value is None:
            value = self.prefixed_default(name, prefix)
        keywords = {'yielding': self.yielding, 'value': value}
        if self.choices:
            keywords['choices'] = self.choices
        return self.opt_type(self.description, **keywords)
def init_option ( self , name : 'OptionKey' , value : T . Optional [ T . Any ] , prefix : str ) -> _U : if value is None : value = self . prefixed_default ( name , prefix ) keywords = { 'yielding' : self . yielding , 'value' : value } if self . choices : keywords [ 'choices' ] = self . choices return self . opt_type ( self . description , * * keywords )