Ņō Ic @ sb d Z d d k Z y e i Z Wn# e j o d d k l Z n Xd e i f d YZ d S( sŪ A subclass of ``optparse.OptionParser`` that allows boolean long options (like ``--verbose``) to also take arguments (like ``--verbose=true``). Arguments *must* use ``=``. iĸĸĸĸN( t gettextt BoolOptionParserc B s e Z d Z RS( c C sī | i d } d | j o2 | i d d \ } } | i d | t } n | } t } | i | } | i | } | i oĶ | i } t | | j oI | d j o | i t d | q%| i t d | | f q| d j o | i d } qt | d | ! } | d | 5nr | od | d i i } | d d 5| d j o d } q| d j o d S| i t d | n d } | i | | | | d S( Ni t =i s %s option requires an arguments %s option requires %d argumentst truet yest ont 1t yt tt falset not offt 0t nt fs1 %s option takes a boolean value only (true/false)( R R R R R R ( R R R R R R ( t popt splitt insertt Truet Falset _match_long_optt _long_optt takes_valuet nargst lent errort _t tuplet lowert stript Nonet process( t selft rargst valuest argt optt next_argt had_explicit_valuet optionR t value( ( s> /usr/lib/python2.6/site-packages/paste/script/bool_optparse.pyt _process_long_opt s<