def set_config(self, config, and_restart=False):
assert isinstance(config, dict)<EOL>self.post('<STR_LIT>', data=config)<EOL>if and_restart:<EOL><INDENT>self.restart()<EOL><DEDENT>
Post the full contents of the configuration, in the same format as
        returned by :func:`.config`. The configuration will be saved to disk
        and the ``configInSync`` flag set to ``False``. Restart Syncthing to
        activate.