Hide module function definitions
Jean Brouwers
mrjean1 at comcast.net
Tue Jun 15 16:05:28 EDT 2004
There are two options:
1) Explicitly list the functions, classes, etc. to be exported by the
module in a list called __all__ inside the module.
2) Start the names of functions, classes, etc. private to the module
with an underscore character.
/Jean Brouwers
ProphICy Semiconductor, Inc.
In article <cammdg$g9o$1 at voyager.news.surf.net>, Raymond Tinsel
<tinsel at wt.tno.nl> wrote:
> Hello all,
>
> I know this must be a newbie question, but I haven't found the solution in
> the tutorials I have read.
>
> For a dSPACE/Controldesk application I am defining several of my own
> modules.
> In those modules I also have function definitions of functions I only use in
> that module.
> Is it possible to hide these functions when somebody would use "import
> mymodule"?
>
> Thanks in advance!
>
> - Raymond
>
> P.S.: Any links to usefull documentation regarding Python (or Python for
> dSPACE in specific) would also be greatly appreciated!
>
>
More information about the Python-list
mailing list