<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to 15: Efficient convenience methods for IfThenElseBlock, LoopBlock</title><link>https://sourceforge.net/p/jode/feature-requests/15/</link><description>Recent changes to 15: Efficient convenience methods for IfThenElseBlock, LoopBlock</description><atom:link href="https://sourceforge.net/p/jode/feature-requests/15/feed.rss" rel="self"/><language>en</language><lastBuildDate>Mon, 22 Jan 2007 08:56:17 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/jode/feature-requests/15/feed.rss" rel="self" type="application/rss+xml"/><item><title>Efficient convenience methods for IfThenElseBlock, LoopBlock</title><link>https://sourceforge.net/p/jode/feature-requests/15/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;In IfThenElseBlock, there is no obvious mechanism for checking whether it has an "else" part. The only way is to check whether getSubBlocks() returns an array of length 1 or 2, but that allocates memory on every call. That's why it would be nice to have the following method added to IfThenElseBlock:&lt;/p&gt;
&lt;p&gt;public boolean hasElse() {&lt;br /&gt;
return elseBlock != null;&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;Along those same lines, you can't obtain a handle to a LoopBlock's body without allocating memory (on each call to getSubBlocks()). Therefore, it would be nice to have the following method in LoopBlock.java:&lt;/p&gt;
&lt;p&gt;public StructuredBlock getBody() {&lt;br /&gt;
return bodyBlock;&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;Thanks!&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Trevor Harmon</dc:creator><pubDate>Mon, 22 Jan 2007 08:56:17 -0000</pubDate><guid>https://sourceforge.net51ddb779bb1cc95cdc3f502cc52b0b154c38a3bb</guid></item></channel></rss>