code: public static String getExpressionKey(String result)
     {
        if (result == null)
           return null;
        try
        {
           int from = result.indexOf(startTag);
           int to = result.indexOf(endTag, from);
           Integer.parseInt(result.substring(from + 5, to));
           return result.substring(from, to + 5);
        }
        catch (Exception e)
        {
           return null;
        }
     }
docs: Get an entities map key from the string
  @param result the string where to find the key
  @return the key or null if nothing was found