docs: @FFDCIgnore(Exception.class)
      public List<String> getEntityType(String entity) {
  
          if (isSafRegistry()) {
              try {
                  if (userRegistry.isValidUser(entity)) {
                      List<String> returnValue = new ArrayList<String>();
                      returnValue.add(SchemaConstants.DO_PERSON_ACCOUNT);
                      returnValue.add(userRegistry.getUserSecurityName(entity)); // Handle SAF tokens.
                      return returnValue;
                  }
              } catch (Exception e) {
                  /* Ignore. */
              }
  
              try {
                  if (userRegistry.isValidGroup(entity)) {
                      List<String> returnValue = new ArrayList<String>();
                      returnValue.add(SchemaConstants.DO_GROUP);
                      returnValue.add(userRegistry.getGroupSecurityName(entity)); // Handle SAF tokens.
                      return returnValue;
                  }
              } catch (Exception e) {
                  /* Ignore. */
              }
          } else {
              try {
                  SearchResult result = userRegistry.getUsers(entity, 1);
                  if (result != null && result.getList().size() > 0) {
                      List<String> returnValue = new ArrayList<String>();
                      returnValue.add(SchemaConstants.DO_PERSON_ACCOUNT);
                      returnValue.add(entity);
                      return returnValue;
                  }
              } catch (Exception e) {
                  /* Ignore. */
              }
  
              try {
                  SearchResult result = userRegistry.getGroups(entity, 1);
                  if (result != null && result.getList().size() > 0) {
                      List<String> returnValue = new ArrayList<String>();
                      returnValue.add(SchemaConstants.DO_GROUP);
                      returnValue.add(entity);
                      return returnValue;
                  }
              } catch (Exception e) {
                  /* Ignore. */
              }
  
              try {
                  String result = userRegistry.getUserSecurityName(entity);
                  if (result != null) {
                      List<String> returnValue = new ArrayList<String>();
                      returnValue.add(SchemaConstants.DO_PERSON_ACCOUNT);
                      returnValue.add(result);
                      return returnValue;
                  }
              } catch (Exception e) {
                  /* Ignore. */
              }
  
              try {
                  String result = userRegistry.getGroupSecurityName(entity);
                  if (result != null) {
                      List<String> returnValue = new ArrayList<String>();
                      returnValue.add(SchemaConstants.DO_GROUP);
                      returnValue.add(result);
                      return returnValue;
                  }
              } catch (Exception e) {
                  /* Ignore. */
              }
          }
  
          return null;
      }