Qucs-S S-parameter Viewer & RF Synthesis Tools
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | List of all members
docutils.core.Publisher Class Reference

Public Member Functions

 __init__ (self, reader=None, parser=None, writer=None, source=None, source_class=io.FileInput, destination=None, destination_class=io.FileOutput, settings=None)
 
 set_reader (self, reader_name, parser, parser_name)
 
 set_writer (self, writer_name)
 
 set_components (self, reader_name, parser_name, writer_name)
 
 setup_option_parser (self, usage=None, description=None, settings_spec=None, config_section=None, **defaults)
 
 get_settings (self, usage=None, description=None, settings_spec=None, config_section=None, **defaults)
 
 process_programmatic_settings (self, settings_spec, settings_overrides, config_section)
 
 process_command_line (self, argv=None, usage=None, description=None, settings_spec=None, config_section=None, **defaults)
 
 set_io (self, source_path=None, destination_path=None)
 
 set_source (self, source=None, source_path=None)
 
 set_destination (self, destination=None, destination_path=None)
 
 apply_transforms (self)
 
 publish (self, argv=None, usage=None, description=None, settings_spec=None, settings_overrides=None, config_section=None, enable_exit_status=False)
 
 debugging_dumps (self)
 
 prompt (self)
 
 report_Exception (self, error)
 
 report_SystemMessage (self, error)
 
 report_UnicodeError (self, error)
 

Public Attributes

 document
 
 reader
 
 parser
 
 writer
 
 source
 
 source_class
 
 destination
 
 destination_class
 
 settings
 

Protected Member Functions

 _setup_settings_parser (self, *args, **kwargs)
 

Protected Attributes

 _stderr
 

Detailed Description

A facade encapsulating the high-level logic of a Docutils system.

Constructor & Destructor Documentation

◆ __init__()

docutils.core.Publisher.__init__ (   self,
  reader = None,
  parser = None,
  writer = None,
  source = None,
  source_class = io.FileInput,
  destination = None,
  destination_class = io.FileOutput,
  settings = None 
)
Initial setup.  If any of `reader`, `parser`, or `writer` are not
specified, ``set_components()`` or the corresponding ``set_...()``
method should be called with component names
(`set_reader` sets the parser as well).

Member Function Documentation

◆ get_settings()

docutils.core.Publisher.get_settings (   self,
  usage = None,
  description = None,
  settings_spec = None,
  config_section = None,
**  defaults 
)
Return settings from components and config files.

Please set components first (`self.set_reader` & `self.set_writer`).
Use keyword arguments to override component defaults
(before updating from configuration files).

Calling this function also sets `self.settings` which makes
`self.publish()` skip parsing command line options.

◆ process_command_line()

docutils.core.Publisher.process_command_line (   self,
  argv = None,
  usage = None,
  description = None,
  settings_spec = None,
  config_section = None,
**  defaults 
)
Parse command line arguments and set ``self.settings``.

Pass an empty sequence to `argv` to avoid reading `sys.argv`
(the default behaviour).

Set components first (`self.set_reader` & `self.set_writer`).

◆ prompt()

docutils.core.Publisher.prompt (   self)
Print info and prompt when waiting for input from a terminal.

◆ publish()

docutils.core.Publisher.publish (   self,
  argv = None,
  usage = None,
  description = None,
  settings_spec = None,
  settings_overrides = None,
  config_section = None,
  enable_exit_status = False 
)
Process command line options and arguments (if `self.settings` not
already set), run `self.reader` and then `self.writer`.  Return
`self.writer`'s output.

◆ set_reader()

docutils.core.Publisher.set_reader (   self,
  reader_name,
  parser,
  parser_name 
)
Set `self.reader` by name.

◆ set_writer()

docutils.core.Publisher.set_writer (   self,
  writer_name 
)
Set `self.writer` by name.

The documentation for this class was generated from the following file: