Skip to main content

@public decorator, public(*objects) function - add objects names to __all__

Project description

https://img.shields.io/badge/language-python-blue.svg https://img.shields.io/pypi/pyversions/public.svg

codacy.com landscape.io codeclimate.com scrutinizer-ci.com

Install

[sudo] pip install public

Usage

>>> from public import public

>>> @public # decorator

>>> public(*objects) # function

Example

>>> @public
        def func(): pass

>>> @public
        class CLS: pass

>>> print(__all__)
['CLS',func']

# public(*objects) function
>>> public("name")
>>> public("name1","name2")

>>> print(__all__)
['name','name1','name2']

Examples/

Sources:

Feedback github_issues gitter github_follow


russianidiot.github.io/python/ - Python packages

russianidiot.github.io/cli/ - command line scripts

README.rst - generated with readmemako.py (python+ mako templates) and .README dotfiles

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

public-0.0.33.tar.gz (7.5 kB view details)

Uploaded Source

File details

Details for the file public-0.0.33.tar.gz.

File metadata

  • Download URL: public-0.0.33.tar.gz
  • Upload date:
  • Size: 7.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for public-0.0.33.tar.gz
Algorithm Hash digest
SHA256 9bce99c16d6cb86d990c4b81359e299e0eff5bfd601f90dd66ca262ced1a2418
MD5 02823d7defce35abe175f5f634e65b2d
BLAKE2b-256 bb0f0ffdafc2949a2e979623b602d17c13df3f9beba2199604667e7e7ddecc20

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page