<html>
<head>
<style><!--
  body {background-color:#ffffff;}
  .file {border:1px solid #eeeeee;margin-top:1em;margin-bottom:1em;}
  .pathname {font-family:monospace; float:right;}
  .fileheader {margin-bottom:.5em;}
  .diff {margin:0;}
  .tasklist {padding:4px;border:1px dashed #000000;margin-top:1em;}
  .tasklist ul {margin-top:0;margin-bottom:0;}
  tr.alt {background-color:#eeeeee}
  #added {background-color:#ddffdd;}
  #addedchars {background-color:#99ff99;font-weight:bolder;}
  tr.alt #added {background-color:#ccf7cc;}
  #removed {background-color:#ffdddd;}
  #removedchars {background-color:#ff9999;font-weight:bolder;}
  tr.alt #removed {background-color:#f7cccc;}
  #copied {background-color:#ccccff;}
  tr.alt #copied {background-color:#bbbbf7;}
  #info {color:#888888;}
  #context {background-color:#eeeeee;}
  td {padding-left:.3em;padding-right:.3em;}
  tr.head {border-bottom-width:1px;border-bottom-style:solid;}
  tr.head td {padding:0;padding-top:.2em;}
  .task {background-color:#ffff00;}
  .comment {white-space:-moz-pre-wrap;white-space:-pre-wrap;white-space:-o-pre-wrap;white-space:pre-wrap;word-wrap:break-word;padding:4px;border:1px dashed #000000;background-color:#ffffdd}
  .error {color:red;}
  hr {border-width:0px;height:2px;background:black;}
--></style>
</head>
<body>
<table cellspacing="0" cellpadding="0" border="0" rules="cols">
<tr class="head"><td colspan="5">Commit in <b><tt>metaas/trunk/src</tt></b></td></tr>
<tr><td><tt>main/java/uk/co/badgersinfoil/metaas/dom/<a href="#file1">ASSwitchCase.java</a></tt> </td><td></td><td align="right" id="added">+5</td><td></td><td nowrap="nowrap" align="center">636 -&gt; 637</td></tr>
<tr class="alt"><td><tt>main/java/uk/co/badgersinfoil/metaas/impl/<a href="#file2">ASTASSwitchCase.java</a></tt> </td><td></td><td align="right" id="added">+5</td><td></td><td nowrap="nowrap" align="center">636 -&gt; 637</td></tr>
<tr><td><tt>test/java/uk/co/badgersinfoil/metaas/<a href="#file3">StatementTests.java</a></tt> </td><td></td><td align="right" id="added">+1</td><td></td><td nowrap="nowrap" align="center">636 -&gt; 637</td></tr>
<tr><td></td><td></td><td align="right" id="added">+11</td><td></td><td></td></tr>
</table>
<small id="info">3 modified files</small><br />
<pre class="comment">
support access to case-clause label value as an ASExpression
</pre>
<hr /><a name="file1" /><div class="file">
<span class="pathname">metaas/trunk/src/main/java/uk/co/badgersinfoil/metaas/dom</span><br />
<div class="fileheader"><big><b>ASSwitchCase.java</b></big> <small id="info">636 -&gt; 637</small></div>
<pre class="diff"><small id="info">--- trunk/src/main/java/uk/co/badgersinfoil/metaas/dom/ASSwitchCase.java        2008-01-27 23:10:20 UTC (rev 636)
+++ trunk/src/main/java/uk/co/badgersinfoil/metaas/dom/ASSwitchCase.java        2008-01-27 23:22:06 UTC (rev 637)
@@ -16,6 +16,11 @@
</small></pre><pre class="diff" id="context"> public interface ASSwitchCase extends SwitchLabel {
 
         /**
</pre><pre class="diff" id="added">+         * Returns a the value expression for this label.
+         */
+        public ASExpression getLabelValue();
+        
+        /**
</pre><pre class="diff" id="context">          * Returns a string representation of the value expression for this
          * label.  e.g. given the label &lt;code&gt;case 42:&lt;/code&gt;, this method
          * would return the string &lt;code&gt;"42"&lt;/code&gt;.
</pre></div>
<hr /><a name="file2" /><div class="file">
<span class="pathname">metaas/trunk/src/main/java/uk/co/badgersinfoil/metaas/impl</span><br />
<div class="fileheader"><big><b>ASTASSwitchCase.java</b></big> <small id="info">636 -&gt; 637</small></div>
<pre class="diff"><small id="info">--- trunk/src/main/java/uk/co/badgersinfoil/metaas/impl/ASTASSwitchCase.java        2008-01-27 23:10:20 UTC (rev 636)
+++ trunk/src/main/java/uk/co/badgersinfoil/metaas/impl/ASTASSwitchCase.java        2008-01-27 23:22:06 UTC (rev 637)
@@ -6,6 +6,7 @@
</small></pre><pre class="diff" id="context"> 
 package uk.co.badgersinfoil.metaas.impl;
 
</pre><pre class="diff" id="added">+import uk.co.badgersinfoil.metaas.dom.ASExpression;
</pre><pre class="diff" id="context"> import uk.co.badgersinfoil.metaas.dom.ASSwitchCase;
 import uk.co.badgersinfoil.metaas.dom.StatementContainer;
 import uk.co.badgersinfoil.metaas.impl.antlr.LinkedListTree;
</pre><pre class="diff"><small id="info">@@ -20,6 +21,10 @@
</small></pre><pre class="diff" id="context">                 this.ast = ast;
         }
 
</pre><pre class="diff" id="added">+        public ASExpression getLabelValue() {
+                return ExpressionBuilder.build(getChild(INDEX_LABELVAL));
+        }
+        
</pre><pre class="diff" id="context">         public String getLabelValueString() {
                 return ASTUtils.stringifyNode(getChild(INDEX_LABELVAL));
         }
</pre></div>
<hr /><a name="file3" /><div class="file">
<span class="pathname">metaas/trunk/src/test/java/uk/co/badgersinfoil/metaas</span><br />
<div class="fileheader"><big><b>StatementTests.java</b></big> <small id="info">636 -&gt; 637</small></div>
<pre class="diff"><small id="info">--- trunk/src/test/java/uk/co/badgersinfoil/metaas/StatementTests.java        2008-01-27 23:10:20 UTC (rev 636)
+++ trunk/src/test/java/uk/co/badgersinfoil/metaas/StatementTests.java        2008-01-27 23:22:06 UTC (rev 637)
@@ -234,6 +234,7 @@
</small></pre><pre class="diff" id="context">                 assertFalse("Empty case statement claims to contain code", cas.containsCode());
                 cas.addStmt("trace(1)");
                 assertEquals("1", cas.getLabelValueString());
</pre><pre class="diff" id="added">+                ExtraAssertions.assertInstanceof(cas.getLabelValue(), ASIntegerLiteral.class);
</pre><pre class="diff" id="context">                 cas.setLabelValue("2");
                 assertEquals("2", cas.getLabelValueString());
                 ASSwitchDefault def= swtch.newDefault();
</pre></div>
<center><small><a href="http://www.badgers-in-foil.co.uk/projects/cvsspam/" title="commit -&gt; email">CVSspam</a> 0.2.12</small></center>
</body></html>