docs: @Override
      public List<Category> getCategories() throws BlogClientException {
  
          final ArrayList<Category> ret = new ArrayList<Category>();
  
          try {
  
              final Object result = getXmlRpcClient().execute("metaWeblog.getCategories", new Object[] { blogid, userName, password });
  
              if (result != null && result instanceof HashMap) {
  
                  // Standard MetaWeblog API style: struct of struts
                  @SuppressWarnings("unchecked")
                  final Map<String, Object> catsmap = (Map<String, Object>) result;
  
                  final Set<String> keys = catsmap.keySet();
                  for (final String key : keys) {
                      @SuppressWarnings("unchecked")
                      final Map<String, Object> catmap = (Map<String, Object>) catsmap.get(key);
                      final BlogEntry.Category category = new BlogEntry.Category(key);
                      final String description = (String) catmap.get("description");
                      category.setName(description);
                      // catmap.get("htmlUrl");
                      // catmap.get("rssUrl");
                      ret.add(category);
                  }
  
              } else if (result != null && result instanceof Object[]) {
                  // Wordpress style: array of structs
                  final Object[] array = (Object[]) result;
                  for (final Object map : array) {
                      @SuppressWarnings("unchecked")
                      final Map<String, Object> catmap = (Map<String, Object>) map;
                      final String categoryId = (String) catmap.get("categoryId");
                      final String categoryName = (String) catmap.get("categoryName");
                      final BlogEntry.Category category = new BlogEntry.Category(categoryId);
                      category.setName(categoryName);
                      ret.add(category);
                  }
              }
          } catch (final Exception e) {
              e.printStackTrace();
          }
  
          return ret;
  
      }