| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173 |
- <!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="X-UA-Compatible" content="IE=Edge" />
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title>pypdevsbbl.extra.packaging module — Python(P)DEVS-BBL documentation</title>
- <link rel="stylesheet" href="_static/nature.css" type="text/css" />
- <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
- <link rel="stylesheet" type="text/css" href="_static/custom.css" />
- <script type="text/javascript" id="documentation_options" data-url_root="./" src="_static/documentation_options.js"></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>
- <script type="text/javascript" src="_static/language_data.js"></script>
- <script async="async" type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/latest.js?config=TeX-AMS-MML_HTMLorMML"></script>
- <link rel="index" title="Index" href="genindex.html" />
- <link rel="search" title="Search" href="search.html" />
- <link rel="next" title="pypdevsbbl.extra.queues module" href="pypdevsbbl.extra.queues.html" />
- <link rel="prev" title="pypdevsbbl.extra.mathutils module" href="pypdevsbbl.extra.mathutils.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="right" >
- <a href="py-modindex.html" title="Python Module Index"
- >modules</a> |</li>
- <li class="right" >
- <a href="pypdevsbbl.extra.queues.html" title="pypdevsbbl.extra.queues module"
- accesskey="N">next</a> |</li>
- <li class="right" >
- <a href="pypdevsbbl.extra.mathutils.html" title="pypdevsbbl.extra.mathutils module"
- accesskey="P">previous</a> |</li>
- <li class="nav-item nav-item-0"><a href="index.html">Python(P)DEVS-BBL documentation</a> »</li>
- <li class="nav-item nav-item-1"><a href="pypdevsbbl.html" >pypdevsbbl package</a> »</li>
- <li class="nav-item nav-item-2"><a href="pypdevsbbl.extra.html" accesskey="U">pypdevsbbl.extra package</a> »</li>
- </ul>
- </div>
- <div class="document">
- <div class="documentwrapper">
- <div class="bodywrapper">
- <div class="body" role="main">
-
- <div class="section" id="module-pypdevsbbl.extra.packaging">
- <span id="pypdevsbbl-extra-packaging-module"></span><h1>pypdevsbbl.extra.packaging module<a class="headerlink" href="#module-pypdevsbbl.extra.packaging" title="Permalink to this headline">¶</a></h1>
- <p>Helper file for <a class="reference internal" href="pypdevsbbl.generic.transformers.html#pypdevsbbl.generic.transformers.Pack" title="pypdevsbbl.generic.transformers.Pack"><code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevsbbl.generic.transformers.Pack</span></code></a> and <a class="reference internal" href="pypdevsbbl.generic.transformers.html#pypdevsbbl.generic.transformers.Unpack" title="pypdevsbbl.generic.transformers.Unpack"><code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevsbbl.generic.transformers.Unpack</span></code></a> blocks.</p>
- <p>The classes in this file represent generic containers in which items can be “packed” together.</p>
- <dl class="class">
- <dt id="pypdevsbbl.extra.packaging.Package">
- <em class="property">class </em><code class="descclassname">pypdevsbbl.extra.packaging.</code><code class="descname">Package</code><span class="sig-paren">(</span><em>*args</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/extra/packaging.html#Package"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.extra.packaging.Package" title="Permalink to this definition">¶</a></dt>
- <dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
- <p>Generic container that holds items.</p>
- <p>All custom containers must inherit from this class,
- or implement the same methods.</p>
- <table class="docutils field-list" frame="void" rules="none">
- <col class="field-name" />
- <col class="field-body" />
- <tbody valign="top">
- <tr class="field-odd field"><th class="field-name">Variables:</th><td class="field-body"><strong>contents</strong> (<em>list</em>) – A container for all packed items.</td>
- </tr>
- </tbody>
- </table>
- <dl class="method">
- <dt id="pypdevsbbl.extra.packaging.Package.pack">
- <code class="descname">pack</code><span class="sig-paren">(</span><em>new</em>, <em>elapsed=0.0</em>, <em>time=0.0</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/extra/packaging.html#Package.pack"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.extra.packaging.Package.pack" title="Permalink to this definition">¶</a></dt>
- <dd><p>Packs a new item in this package.</p>
- <table class="docutils field-list" frame="void" rules="none">
- <col class="field-name" />
- <col class="field-body" />
- <tbody valign="top">
- <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple">
- <li><strong>new</strong> (<em>any</em>) – The new object to join to the package.</li>
- <li><strong>elapsed</strong> (<em>numeric</em>) – The elpased time since the last package.
- Defaults to 0.</li>
- <li><strong>time</strong> (<em>numeric</em>) – The total simulation time. Defaults to 0.</li>
- </ul>
- </td>
- </tr>
- </tbody>
- </table>
- </dd></dl>
- <dl class="method">
- <dt id="pypdevsbbl.extra.packaging.Package.unpack">
- <code class="descname">unpack</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/extra/packaging.html#Package.unpack"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.extra.packaging.Package.unpack" title="Permalink to this definition">¶</a></dt>
- <dd><p>Releases the contents of this package.</p>
- <p>After this method is executed, the Package must be in its original state.</p>
- </dd></dl>
- <dl class="method">
- <dt id="pypdevsbbl.extra.packaging.Package.finished">
- <code class="descname">finished</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/extra/packaging.html#Package.finished"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.extra.packaging.Package.finished" title="Permalink to this definition">¶</a></dt>
- <dd><p>Indicates if the package is finished or not.</p>
- <p>Whenever this evaluates to <code class="docutils literal notranslate"><span class="pre">True</span></code> after a <a class="reference internal" href="#pypdevsbbl.extra.packaging.Package.pack" title="pypdevsbbl.extra.packaging.Package.pack"><code class="xref py py-meth docutils literal notranslate"><span class="pre">pack()</span></code></a>-call, the package
- should be released automatically.</p>
- </dd></dl>
- </dd></dl>
- <dl class="class">
- <dt id="pypdevsbbl.extra.packaging.SizedPackage">
- <em class="property">class </em><code class="descclassname">pypdevsbbl.extra.packaging.</code><code class="descname">SizedPackage</code><span class="sig-paren">(</span><em>size</em><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/extra/packaging.html#SizedPackage"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.extra.packaging.SizedPackage" title="Permalink to this definition">¶</a></dt>
- <dd><p>Bases: <a class="reference internal" href="#pypdevsbbl.extra.packaging.Package" title="pypdevsbbl.extra.packaging.Package"><code class="xref py py-class docutils literal notranslate"><span class="pre">pypdevsbbl.extra.packaging.Package</span></code></a></p>
- <p>A <a class="reference internal" href="#pypdevsbbl.extra.packaging.Package" title="pypdevsbbl.extra.packaging.Package"><code class="xref py py-class docutils literal notranslate"><span class="pre">Package</span></code></a> that has a maximal size.</p>
- <dl class="method">
- <dt id="pypdevsbbl.extra.packaging.SizedPackage.finished">
- <code class="descname">finished</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="reference internal" href="_modules/pypdevsbbl/extra/packaging.html#SizedPackage.finished"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#pypdevsbbl.extra.packaging.SizedPackage.finished" title="Permalink to this definition">¶</a></dt>
- <dd></dd></dl>
- </dd></dl>
- </div>
- </div>
- </div>
- </div>
- <div class="sphinxsidebar" role="navigation" aria-label="main navigation">
- <div class="sphinxsidebarwrapper">
- <h4>Previous topic</h4>
- <p class="topless"><a href="pypdevsbbl.extra.mathutils.html"
- title="previous chapter">pypdevsbbl.extra.mathutils module</a></p>
- <h4>Next topic</h4>
- <p class="topless"><a href="pypdevsbbl.extra.queues.html"
- title="next chapter">pypdevsbbl.extra.queues module</a></p>
- <div id="searchbox" style="display: none" role="search">
- <h3>Quick search</h3>
- <div class="searchformwrapper">
- <form class="search" action="search.html" method="get">
- <input type="text" name="q" />
- <input type="submit" value="Go" />
- <input type="hidden" name="check_keywords" value="yes" />
- <input type="hidden" name="area" value="default" />
- </form>
- </div>
- </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="right" >
- <a href="py-modindex.html" title="Python Module Index"
- >modules</a> |</li>
- <li class="right" >
- <a href="pypdevsbbl.extra.queues.html" title="pypdevsbbl.extra.queues module"
- >next</a> |</li>
- <li class="right" >
- <a href="pypdevsbbl.extra.mathutils.html" title="pypdevsbbl.extra.mathutils module"
- >previous</a> |</li>
- <li class="nav-item nav-item-0"><a href="index.html">Python(P)DEVS-BBL documentation</a> »</li>
- <li class="nav-item nav-item-1"><a href="pypdevsbbl.html" >pypdevsbbl package</a> »</li>
- <li class="nav-item nav-item-2"><a href="pypdevsbbl.extra.html" >pypdevsbbl.extra package</a> »</li>
- </ul>
- </div>
- <div class="footer" role="contentinfo">
- © Copyright 2020, Randy Paredis.
- Created using <a href="http://sphinx-doc.org/">Sphinx</a> 1.8.5.
- </div>
- </body>
- </html>
|