public static Tile of(final String representation) {
            if ("  ".equals(representation)) {
                return AIR;
            } else if ("##".equals(representation)) {
                return WALL;
            } else if ("[]".equals(representation)) {
                return TAVERN;
            } else if ("$-".equals(representation)) {
                return FREE_MINE;
            } else if (representation.startsWith("$")) {
                try {
                    return Mine(Integer.parseInt(representation.substring(1)));
                } catch (Exception e) {
                    throw new IllegalArgumentException("Invalid mine tile: " + representation.substring(1));

                } // end of catch
            } else if (representation.startsWith("@")) {
                try {
                    return Hero(Integer.parseInt(representation.substring(1)));
                } catch (Exception e) {
                    throw new IllegalArgumentException("Invalid hero tile: " + representation.substring(1));

                } // end of catch
            } // end of else if

            throw new IllegalArgumentException("Unsupported tile: " + representation);

        } // end of valueOf