issue in using recursive function

shubhashish rudra <[email protected]> Fri, 28 Nov 2014 10:49:03 +0000 (UTC)
Newsgroups gmane.comp.python.cheetah
Message-ID <836446740.2141169.1417171743386.JavaMail.yahoo@jws10616.mail.bf1.yahoo.com>
--===============3249439435121279988==
Content-Type: multipart/alternative; 
	boundary="----=_Part_2141168_55761305.1417171743382"
Content-Length: 3472

------=_Part_2141168_55761305.1417171743382
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable


Hi,=C2=A0I tried using the function in recursive way and it gives errorType=
Error: 'NoneType' object is not iterable=C2=A0def analyzeDir1(curdir)
=C2=A0#for $file1 in curdir.filer
=C2=A0=C2=A0=C2=A0 puts "$file1 "
=C2=A0#end for
=C2=A0#for $cc in curdir.dir
=C2=A0$cc.name
=C2=A0$analyzeDir1($cc)
=C2=A0#end for
#end def=C2=A0the xml is <directorystructure>
=C2=A0=C2=A0 <dir type=3D"dir" name=3D"version">
=C2=A0=C2=A0=C2=A0=C2=A0 <filer type=3D"required">{package}.skill.ile</file=
r>
=C2=A0=C2=A0=C2=A0=C2=A0 <filer type=3D"optional">{package}.skill.ele.opt</=
filer>
=C2=A0=C2=A0=C2=A0=C2=A0 <filer type=3D"required">{package}.tt</filer>
=C2=A0=C2=A0=C2=A0=C2=A0 <dir type=3D"dir"=C2=A0 name=3D"etc">
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 <filer type=3D"required">{package}.tt1=
</filer>
=C2=A0=C2=A0=C2=A0=C2=A0 </dir>
=C2=A0=C2=A0 </dir>
</directorystructure>=C2=A0Can someone let me know if recursive function is=
 not supported.=C2=A0Regards,Shubhashish

------=_Part_2141168_55761305.1417171743382
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div style=3D"color: rgb(0, 0, 0); font-family: HelveticaNeue, Helvetica Ne=
ue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 12px; backgroun=
d-color: rgb(255, 255, 255);"><div id=3D"yui_3_16_0_1_1417171159886_7687" d=
ir=3D"ltr"><br>Hi,</div><div id=3D"yui_3_16_0_1_1417171159886_7778" dir=3D"=
ltr">&nbsp;</div><div id=3D"yui_3_16_0_1_1417171159886_7779" dir=3D"ltr">I =
tried using the function in recursive way and it gives error</div><div id=
=3D"yui_3_16_0_1_1417171159886_7812" dir=3D"ltr">TypeError: 'NoneType' obje=
ct is not iterable</div><div id=3D"yui_3_16_0_1_1417171159886_7813" dir=3D"=
ltr">&nbsp;</div><div id=3D"yui_3_16_0_1_1417171159886_7790" dir=3D"ltr">de=
f analyzeDir1(curdir)<br>&nbsp;#for $file1 in curdir.filer<br>&nbsp;&nbsp;&=
nbsp; puts "$file1 "<br>&nbsp;#end for<br>&nbsp;#for $cc in curdir.dir<br>&=
nbsp;$cc.name<br>&nbsp;$analyzeDir1($cc)<br>&nbsp;#end for<br>#end def</div=
><div id=3D"yui_3_16_0_1_1417171159886_7800" dir=3D"ltr">&nbsp;</div><div i=
d=3D"yui_3_16_0_1_1417171159886_7802" dir=3D"ltr">the xml is </div><div id=
=3D"yui_3_16_0_1_1417171159886_7823" dir=3D"ltr">&lt;directorystructure&gt;=
<br>&nbsp;&nbsp; &lt;dir type=3D"dir" name=3D"version"&gt;<br>&nbsp;&nbsp;&=
nbsp;&nbsp; &lt;filer type=3D"required"&gt;{package}.skill.ile&lt;/filer&gt=
;<br>&nbsp;&nbsp;&nbsp;&nbsp; &lt;filer type=3D"optional"&gt;{package}.skil=
l.ele.opt&lt;/filer&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp; &lt;filer type=3D"requi=
red"&gt;{package}.tt&lt;/filer&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp; &lt;dir type=
=3D"dir"&nbsp; name=3D"etc"&gt;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt=
;filer type=3D"required"&gt;{package}.tt1&lt;/filer&gt;<br>&nbsp;&nbsp;&nbs=
p;&nbsp; &lt;/dir&gt;<br>&nbsp;&nbsp; &lt;/dir&gt;<br>&lt;/directorystructu=
re&gt;</div><div id=3D"yui_3_16_0_1_1417171159886_7824" dir=3D"ltr">&nbsp;<=
/div><div id=3D"yui_3_16_0_1_1417171159886_7836" dir=3D"ltr">Can someone le=
t me know if recursive function is not supported.</div><div id=3D"yui_3_16_=
0_1_1417171159886_7837" dir=3D"ltr">&nbsp;</div><div id=3D"yui_3_16_0_1_141=
7171159886_7825" dir=3D"ltr">Regards,</div><div id=3D"yui_3_16_0_1_14171711=
59886_7826" dir=3D"ltr">Shubhashish<br></div></div>
------=_Part_2141168_55761305.1417171743382--


--===============3249439435121279988==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
--===============3249439435121279988==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Cheetahtemplate-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss

--===============3249439435121279988==--