久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

<legend id='2aNXk'><style id='2aNXk'><dir id='2aNXk'><q id='2aNXk'></q></dir></style></legend>

  • <tfoot id='2aNXk'></tfoot>

    <small id='2aNXk'></small><noframes id='2aNXk'>

    • <bdo id='2aNXk'></bdo><ul id='2aNXk'></ul>

    <i id='2aNXk'><tr id='2aNXk'><dt id='2aNXk'><q id='2aNXk'><span id='2aNXk'><b id='2aNXk'><form id='2aNXk'><ins id='2aNXk'></ins><ul id='2aNXk'></ul><sub id='2aNXk'></sub></form><legend id='2aNXk'></legend><bdo id='2aNXk'><pre id='2aNXk'><center id='2aNXk'></center></pre></bdo></b><th id='2aNXk'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='2aNXk'><tfoot id='2aNXk'></tfoot><dl id='2aNXk'><fieldset id='2aNXk'></fieldset></dl></div>

      1. python __all__ 模塊級變量有什么用?

        What#39;s the python __all__ module level variable for?(python __all__ 模塊級變量有什么用?)

          <tbody id='0QZYO'></tbody>
        • <small id='0QZYO'></small><noframes id='0QZYO'>

              <i id='0QZYO'><tr id='0QZYO'><dt id='0QZYO'><q id='0QZYO'><span id='0QZYO'><b id='0QZYO'><form id='0QZYO'><ins id='0QZYO'></ins><ul id='0QZYO'></ul><sub id='0QZYO'></sub></form><legend id='0QZYO'></legend><bdo id='0QZYO'><pre id='0QZYO'><center id='0QZYO'></center></pre></bdo></b><th id='0QZYO'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='0QZYO'><tfoot id='0QZYO'></tfoot><dl id='0QZYO'><fieldset id='0QZYO'></fieldset></dl></div>
              1. <legend id='0QZYO'><style id='0QZYO'><dir id='0QZYO'><q id='0QZYO'></q></dir></style></legend>

                <tfoot id='0QZYO'></tfoot>
                  <bdo id='0QZYO'></bdo><ul id='0QZYO'></ul>
                  本文介紹了python __all__ 模塊級變量有什么用?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  我在 python/Lib 源代碼中看到了很多,但我不知道它是干什么用的.

                  I've seen it a lot in python/Lib source code but I don't know what it is for.

                  我認為它用于限制模塊的可訪問成員.所以只有 __all__ 處的元素會在 dir(module) 時出現.

                  I thought it was used to limit accessible members of of a module. So only the elements at __all__ will show up when dir(module).

                  我做了一個小例子,發現它沒有按預期工作.

                  I did a little example and saw it was not working as I expected.

                  那么... python __all__ 模塊級變量是干什么用的?

                  So... What's the python __all__ module level variable for?

                  推薦答案

                  它有兩個目的:

                  1. 任何閱讀源代碼的人都會知道公開的公共 API 是什么.它不會阻止他們在私有聲明中四處尋找,但確實提供了一個很好的警告.

                  1. Anybody who reads the source will know what the exposed public API is. It doesn't prevent them from poking around in private declarations, but does provide a good warning not to.

                  使用 from mod import * 時,只會導入 __all__ 中列出的名稱.在我看來,這并不重要,因為導入所有內容真的是個壞主意.

                  When using from mod import *, only names listed in __all__ will be imported. This is not as important, in my opinion, because importing everything is a really bad idea.

                  這篇關于python __all__ 模塊級變量有什么用?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  python: Two modules and classes with the same name under different packages(python:不同包下同名的兩個模塊和類)
                  Configuring Python to use additional locations for site-packages(配置 Python 以使用站點包的其他位置)
                  How to structure python packages without repeating top level name for import(如何在不重復導入頂級名稱的情況下構造python包)
                  Install python packages on OpenShift(在 OpenShift 上安裝 python 包)
                  How to refresh sys.path?(如何刷新 sys.path?)
                  Distribute a Python package with a compiled dynamic shared library(分發帶有已編譯動態共享庫的 Python 包)
                      <bdo id='4Hpro'></bdo><ul id='4Hpro'></ul>

                              <tbody id='4Hpro'></tbody>
                          • <small id='4Hpro'></small><noframes id='4Hpro'>

                          • <legend id='4Hpro'><style id='4Hpro'><dir id='4Hpro'><q id='4Hpro'></q></dir></style></legend>

                            <i id='4Hpro'><tr id='4Hpro'><dt id='4Hpro'><q id='4Hpro'><span id='4Hpro'><b id='4Hpro'><form id='4Hpro'><ins id='4Hpro'></ins><ul id='4Hpro'></ul><sub id='4Hpro'></sub></form><legend id='4Hpro'></legend><bdo id='4Hpro'><pre id='4Hpro'><center id='4Hpro'></center></pre></bdo></b><th id='4Hpro'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='4Hpro'><tfoot id='4Hpro'></tfoot><dl id='4Hpro'><fieldset id='4Hpro'></fieldset></dl></div>
                            <tfoot id='4Hpro'></tfoot>
                          • 主站蜘蛛池模板: 成人精品一区亚洲午夜久久久 | 欧美日韩电影一区二区 | 国产91丝袜在线播放 | 欧美三级三级三级爽爽爽 | 国产一区影院 | 成人在线精品视频 | 亚洲 精品 综合 精品 自拍 | 精品日韩一区 | 亚洲电影第三页 | 欧美日韩中文国产一区发布 | 欧美精品一区二区三区在线 | 在线观看视频一区二区三区 | 日韩aⅴ片| 欧美日韩国产一区二区三区 | 国产精品美女久久久久久免费 | 阿v视频在线观看 | 国产成人免费视频网站高清观看视频 | 欧美色综合一区二区三区 | 午夜99| 亚洲国产精品一区 | 国产激情一区二区三区 | 日本免费一区二区三区 | 亚洲精品天堂 | 亚洲国产成人在线观看 | 欧美日韩综合精品 | 97起碰| 成人精品一区二区 | 国产精品视频网 | 精久久久 | www.788.com色淫免费 | 国产在线精品一区二区 | 欧美国产精品久久久 | 波多野结衣先锋影音 | 欧美亚洲另类在线 | 91美女在线 | 成年人免费在线视频 | 欧美理论片在线观看 | 亚洲免费大片 | 天天色图| 在线观看亚洲一区二区 | 国产在线区|