MOON
Server: Apache/2.2.34 (Unix) mod_ssl/2.2.34 OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4 FrontPage/5.0.2.2635
System: Linux server.asjudinet.com 2.6.32-042stab141.3 #1 SMP Fri Nov 15 22:45:34 MSK 2019 i686
User: asjudine (504)
PHP: 5.2.17
Disabled: NONE
Upload Files
File: //proc/2/root/usr/lib/python2.4/Demo/pdist/cmdfw.pyo
mò
‚=5Dc@s>dZdfd„ƒYZd„ZedjoeƒndS(sHFramework for command line interfaces like CVS.  See class CmdFrameWork.tCommandFrameWorkcBs\tZdZdZeZdZd„Zed„Zd„Z	d„Z
ed„Zd„ZRS(	sóFramework class for command line interfaces like CVS.

    The general command line structure is

            command [flags] subcommand [subflags] [argument] ...

    There's a class variable GlobalFlags which specifies the
    global flags options.  Subcommands are defined by defining
    methods named do_<subcommand>.  Flags for the subcommand are
    defined by defining class or instance variables named
    flags_<subcommand>.  If there's no command, method default()
    is called.  The __doc__ strings for the do_ methods are used
    for the usage message, printed after the general usage message
    which is the class variable UsageMessage.  The class variable
    PostUsageMessage is printed after all the do_ methods' __doc__
    strings.  The method's return value can be a suggested exit
    status.  [XXX Need to rewrite this to clarify it.]

    Common usage is to derive a class, instantiate it, and then call its
    run() method; by default this takes its arguments from sys.argv[1:].
    s;usage: (name)s [flags] subcommand [subflags] [argument] ...tcCsdS(s&Constructor, present for completeness.N((tself((t&/usr/lib/python2.4/Demo/pdist/cmdfw.pyt__init__#scCsždk}dk}|djo|id}ny|i||iƒ\}
}Wn%|ij
o}|i
|ƒSnX|i|
ƒ|p|iƒ|i
ƒSnø|d}d|}d|}yt||ƒ}	Wn'tj
o|i
d|fƒSnXyt||ƒ}Wntj
o
d}nXy |i|d|ƒ\}
}Wn3|ij
o$}|i
d|t|ƒƒSnX|iƒ|	|
|ƒSdS(	s3Process flags, subcommand and options, then run it.Niitdo_tflags_scommand %r unknownRssubcommand %s: (tgetopttsystargstNonetargvRtGlobalFlagstoptsterrortmsgtusagetoptionstreadytdefaulttcmdtmnametfnametgetattrtmethodtAttributeErrortflagststr(RR	RRRRRRRRR
((Rtrun's:





  
cCsT|oIddGHdGHx+|D]#\}}dG|GdGt|ƒGHqWddGHndS(sWProcess the options retrieved by getopt.
        Override this if you have any options.t-i(sOptions:toptiontvalueN(R
totatrepr(RR
R!R ((RRGs	cCsdS(s*Called just before calling the subcommand.N((R((RRQscCs6|o	|GHn|ihd|ii<GHh}|i}xŸx{t|ƒD]m}|d djoV|i	|ƒoqJnyt
||ƒi}Wn
d}nX|o|||<q·qJqJW|ipPn|id}q=W|o9dGH|iƒ}|iƒx|D]}||GHqWn|io|iGHndS(	s4Print usage message.  Return suitable exit code (2).tnameiiRiswhere subcommand can be:iN(RRtUsageMessaget	__class__t__name__t
docstringstctdirR#thas_keyRt__doc__tdocR
t	__bases__tkeystnamestsorttPostUsageMessage(RRR(R#R,R/R'((RRUs@		




cCs	dGHdS(s\Default method, called when no subcommand is given.
        You should always override this.s'Nobody expects the Spanish Inquisition!N((R((RRss(
R&t
__module__R+R$R
R1RRRRRRR(((RRs	 	
	cCs—dk}dtfd„ƒY}|ƒ}gdgdgdgddgdg}xA|D]9}ddG|GddGH|i|ƒ}d	Gt	|ƒGHqVWdS(
s:Test script -- called when this module is run as a script.NtHellocBstZd„ZRS(NcCs	dGHdS(s0hello -- print 'hello world', needs no argumentssHello, worldN((RR
R	((Rtdo_hello}s(R&R2R4(((RR3|sthellotspams-xRi
sExit status:(
RRR3txR
tteststtRtstsR"(R8RR9R:R7R3((Rttestys		't__main__N(R+RR;R&(R;R((Rt?su