Python Library Reference
Previous: Up: 6.21 optparse Next:


6.21.5 Extending optparse

Since the two major controlling factors in how optparse interprets command-line options are the action and type of each option, the most likely direction of extension is to add new actions and new types.

Also, the examples/ directory of the source distribution includes several demonstrations of extending optparse in different ways: e.g. a case-insensitive option parser, or two kinds of option parsers that implement ``required options''.



Subsections

Python Library Reference
Previous: Up: 6.21 optparse Next:

Release 2.4.4, documentation updated on 18 October 2006.
See About this document... for information on suggesting changes.

AltStyle によって変換されたページ (->オリジナル) /