'Apply defaults to output options, or validate the provided ones.
The default output options are stdout-type-sensitive.'

def _process_output_options(self):

    def check_options(value, option):
        unknown = (set(value) - OUTPUT_OPTIONS)
        if unknown:
            self.error('Unknown    output    options:    {0}={1}'.format(option, ','.join(unknown)))
    if self.args.verbose:
        self.args.all = True
    if (self.args.output_options is None):
        if self.args.verbose:
            self.args.output_options = ''.join(OUTPUT_OPTIONS)
        else:
            self.args.output_options = (OUTPUT_OPTIONS_DEFAULT if self.env.stdout_isatty else OUTPUT_OPTIONS_DEFAULT_STDOUT_REDIRECTED)
    if (self.args.output_options_history is None):
        self.args.output_options_history = self.args.output_options
    check_options(self.args.output_options, '--print')
    check_options(self.args.output_options_history, '--history-print')
    if (self.args.download and (OUT_RESP_BODY in self.args.output_options)):
        self.args.output_options = str((set(self.args.output_options) - set(OUT_RESP_BODY)))
