/usr/share/doc/python-mailmanclient/html/_modules/mailmanclient/restobjects/preferences.html is in python-mailmanclient-doc 3.1.1-5.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>mailmanclient.restobjects.preferences — Mailman Client 3.1.1 documentation</title>
<link rel="stylesheet" href="../../../_static/classic.css" type="text/css" />
<link rel="stylesheet" href="../../../_static/pygments.css" type="text/css" />
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../../../',
VERSION: '3.1.1',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: '.txt'
};
</script>
<script type="text/javascript" src="../../../_static/jquery.js"></script>
<script type="text/javascript" src="../../../_static/underscore.js"></script>
<script type="text/javascript" src="../../../_static/doctools.js"></script>
<link rel="index" title="Index" href="../../../genindex.html" />
<link rel="search" title="Search" href="../../../search.html" />
</head>
<body>
<div class="related" role="navigation" aria-label="related navigation">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="nav-item nav-item-0"><a href="../../../README.html">Mailman Client 3.1.1 documentation</a> »</li>
<li class="nav-item nav-item-1"><a href="../../index.html" accesskey="U">Module code</a> »</li>
</ul>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<h1>Source code for mailmanclient.restobjects.preferences</h1><div class="highlight"><pre>
<span></span><span class="c1"># Copyright (C) 2010-2017 The Free Software Foundation, Inc.</span>
<span class="c1">#</span>
<span class="c1"># This file is part of mailmanclient.</span>
<span class="c1">#</span>
<span class="c1"># mailmanclient is free software: you can redistribute it and/or modify it</span>
<span class="c1"># under the terms of the GNU Lesser General Public License as published by the</span>
<span class="c1"># Free Software Foundation, version 3 of the License.</span>
<span class="c1">#</span>
<span class="c1"># mailmanclient is distributed in the hope that it will be useful, but</span>
<span class="c1"># WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY</span>
<span class="c1"># or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public</span>
<span class="c1"># License for more details.</span>
<span class="c1">#</span>
<span class="c1"># You should have received a copy of the GNU Lesser General Public License</span>
<span class="c1"># along with mailmanclient. If not, see <http://www.gnu.org/licenses/>.</span>
<span class="kn">from</span> <span class="nn">mailmanclient.restbase.base</span> <span class="k">import</span> <span class="n">RESTDict</span>
<span class="n">__metaclass__</span> <span class="o">=</span> <span class="nb">type</span>
<span class="n">__all__</span> <span class="o">=</span> <span class="p">[</span>
<span class="s1">'Preferences'</span><span class="p">,</span>
<span class="s1">'PreferencesMixin'</span>
<span class="p">]</span>
<div class="viewcode-block" id="Preferences"><a class="viewcode-back" href="../../../src/mailmanclient/docs/apiref.html#mailmanclient._client.Preferences">[docs]</a><span class="k">class</span> <span class="nc">Preferences</span><span class="p">(</span><span class="n">RESTDict</span><span class="p">):</span>
<span class="n">_properties</span> <span class="o">=</span> <span class="p">(</span>
<span class="s1">'acknowledge_posts'</span><span class="p">,</span> <span class="s1">'delivery_mode'</span><span class="p">,</span> <span class="s1">'delivery_status'</span><span class="p">,</span>
<span class="s1">'hide_address'</span><span class="p">,</span> <span class="s1">'preferred_language'</span><span class="p">,</span> <span class="s1">'receive_list_copy'</span><span class="p">,</span>
<span class="s1">'receive_own_postings'</span><span class="p">,</span>
<span class="p">)</span>
<div class="viewcode-block" id="Preferences.delete"><a class="viewcode-back" href="../../../src/mailmanclient/docs/apiref.html#mailmanclient._client.Preferences.delete">[docs]</a> <span class="k">def</span> <span class="nf">delete</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
<span class="n">response</span><span class="p">,</span> <span class="n">content</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">_connection</span><span class="o">.</span><span class="n">call</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">_url</span><span class="p">,</span> <span class="n">method</span><span class="o">=</span><span class="s1">'DELETE'</span><span class="p">)</span></div></div>
<span class="k">class</span> <span class="nc">PreferencesMixin</span><span class="p">:</span>
<span class="sd">"""Mixin for restobjects that have preferences."""</span>
<span class="nd">@property</span>
<span class="k">def</span> <span class="nf">preferences</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
<span class="k">if</span> <span class="nb">getattr</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="s1">'_preferences'</span><span class="p">,</span> <span class="kc">None</span><span class="p">)</span> <span class="ow">is</span> <span class="kc">None</span><span class="p">:</span>
<span class="n">path</span> <span class="o">=</span> <span class="s1">'</span><span class="si">{0}</span><span class="s1">/preferences'</span><span class="o">.</span><span class="n">format</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">self_link</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">_preferences</span> <span class="o">=</span> <span class="n">Preferences</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">_connection</span><span class="p">,</span> <span class="n">path</span><span class="p">)</span>
<span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">_preferences</span>
</pre></div>
</div>
</div>
</div>
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
<div class="sphinxsidebarwrapper">
<div id="searchbox" style="display: none" role="search">
<h3>Quick search</h3>
<form class="search" action="../../../search.html" method="get">
<div><input type="text" name="q" /></div>
<div><input type="submit" value="Go" /></div>
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="related" role="navigation" aria-label="related navigation">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../../../genindex.html" title="General Index"
>index</a></li>
<li class="nav-item nav-item-0"><a href="../../../README.html">Mailman Client 3.1.1 documentation</a> »</li>
<li class="nav-item nav-item-1"><a href="../../index.html" >Module code</a> »</li>
</ul>
</div>
<div class="footer" role="contentinfo">
© Copyright 2012-2018, The Free Software Foundation.
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.6.7.
</div>
</body>
</html>
|