code: static String ensureExcludesAt(String pSource, String pSubstring, int pPosition) {
          StringBuilder newString = new StringBuilder(pSource);
  
          try {
              String existingString = pSource.substring(pPosition + 1, pPosition + pSubstring.length() + 1);
  
              if (!existingString.equalsIgnoreCase(pSubstring)) {
                  newString.delete(pPosition, pPosition + pSubstring.length());
              }
          }
          catch (Exception e) {
              // Do something!?
          }
          return newString.toString();
      }
docs: Ensures that a string does not include a given substring at a given
  position.
  <p/>
  Removes a given substring from a string if it is there.
  E.g an URL "http://www.vg.no", to "www.vg.no".
  
  @param pSource    The source string.
  @param pSubstring The substring to check and possibly remove.
  @param pPosition  The location of possible substring removal, the index starts with 0.
  @return the string, without the substring at the given location.