Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 13th, 2012  |  syntax: None  |  size: 0.58 KB  |  hits: 27  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. FreeMarker: Check if map value is null
  2. <#list mapMinY..mapMaxY as y>
  3.             <tr>
  4.                 <#list mapMinX..mapMaxX as x>
  5.                     <td>
  6.                         <div>
  7.                             <!-- Check if map[x + " " + y] is null -->
  8.                             ${x}, ${y}
  9.                         </div>
  10.                     </td>
  11.                 </#list>
  12.             </tr>
  13.         </#list>
  14.        
  15. ${map[x + " " + y]!}
  16.    do Stuff
  17. ${map[x + " " + y]!}
  18.        
  19. utilClass.isNull(map[x + " " + y])==true
  20.        
  21. <#if map[x + " " + y]??>It's not null<#else>It's null or missing</#if>