return null;
String attrStr = null; int attrVal = 0; Hex retVal = null;   if ( null == node ) { throw new IllegalArgumentException( "The hex is null." ); }   if ( !node.getName().equals( "hex" ) ) { throw new IllegalStateException( "Not passed a hex node." ); }     Enumeration children = node.elements(); while ( children.hasMoreElements() ) { ParsedXML child = (ParsedXML) children.nextElement(); if ( child.getName().equals( "terrains" ) ) {   if ( null != retVal ) { throw new IllegalStateException ( "More than one 'terrains' node in a hex node." ); }   Terrain[] terrains = new Terrain[Terrain.SIZE];   Enumeration subnodes = child.elements(); while ( subnodes.hasMoreElements() ) {   ParsedXML subnode = (ParsedXML) subnodes.nextElement(); if ( subnode.getName().equals( "terrain" ) ) {   try { final int type = Integer.parseInt ( subnode.getAttribute( "type" ) ); final boolean exitsSpecified = Boolean.getBoolean ( subnode.getAttribute( "exitsSpecified" ) ); final int level = Integer.parseInt ( subnode.getAttribute( "level" ) ); final int exits = Integer.parseInt ( subnode.getAttribute( "exits" ) ); terrains[type] = new Terrain ( type, level, exitsSpecified, exits ); } catch ( Throwable thrown ) { throw new IllegalStateException ( "Couldn't parse a terrain from a hex node." ); }  }  }   attrStr = child.getAttribute( "elevation" ); if ( null == attrStr ) { throw new IllegalStateException ( "Couldn't decode the terrains for a hex node." ); }   try { attrVal = Integer.parseInt( attrStr ); } catch ( NumberFormatException exp ) { throw new IllegalStateException ( "Couldn't get an integer from " + attrStr ); }   attrStr = child.getAttribute( "theme" );   retVal = new Hex( attrVal, terrains, attrStr );  }  }   return retVal;
    public static Hex decode( ParsedXML node, Game game ) {        return null;    }