Normalize the string for use as a URL slug. Note that in this context,
 +normalize+ means, strip, remove non-letters/numbers, downcasing,
 truncating to 255 bytes and converting whitespace to dashes.
 @param Options
 @return String
558315
def normalize!(options = nil)
      options = default_normalize_options.merge(options || {})

      if translit_option = options[:transliterate]
        if translit_option != true
          transliterate!(*translit_option)
        else
          transliterate!(*options[:transliterations])
        end
      end
      to_ascii! if options[:to_ascii]
      clean!
      word_chars!
      clean!
      downcase!
      truncate_bytes!(options[:max_length])
      with_separators!(options[:separator])
    end
879394
public static function normalizeUrl($url)
        {
            if (substr($url, 0, 1) != '/') $url = '/' . $url;

            if (substr($url, -1) == '/') $url = substr($url, 0, -1);

            if (!strlen($url)) $url = '/';

            return $url;
        }
12137
private static String normalizeURL(String urlString)
            throws MalformedURLException {
        URL url = new URL(urlString);
        if (url.getPort() == -1) {
            return url.getProtocol() + "://" + url.getHost() + ":"
                    + url.getDefaultPort() + url.getFile()
                    + (url.getRef() != null ? "#" + url.getRef() : "");
        } else {
            return urlString;
        }
    }
816747
def normalize_url(url: 'Union[URL, str]') -> 'URL':
    """"""
    url = URL(url)
    return url.with_query(urlencode(sorted(parse_qsl(url.query_string))))
1030786
function normalize(options){
    options = options || {};

    options.printfn = options.printfn || function(obj) {
      console.dir(obj, {colors: true});
    };

   if (!options.accept) {
      if (options.include) {
         options.accept = function(propKey) { return options.include.indexOf(propKey) >= 0; };
      }
      else if (options.exclude){
         options.accept = function(propKey) { return options.exclude.indexOf(propKey) < 0; };
      }
      else {
         options.accept = function() { return true; };
      }
   }

   options.fileFilter = fileFilter(options.filter);

   return options;
}
693155
function normalizeOptions(options = undefined) {
  switch (true) {
    case isPlainObject(options):
      return {
        ...defaults, ...options
      }

    case options && typeof options === "string":
      return {
        ...defaults, encoding: options
      }

    default:
      return defaults
  }
}
546198
function normalizeInject (options) {
  var inject = options.inject;
  if (Array.isArray(inject)) {
    var normalized = options.inject = {};
    for (var i = 0; i < inject.length; i++) {
      normalized[inject[i]] = inject[i];
    }
  }
}
426676
def _normalize_options(options)
        _normalize_text(options)

        if options[:html]
          options[:html] = ERB::Util.html_escape(options[:html])
        end

        if options[:status]
          options[:status] = Rack::Utils.status_code(options[:status])
        end

        super
      end
756270
private String normalize(String user) {
        if(user != null){
            if(user.contains("@"))
                user = user.replaceAll("@", "%40");
        }
        if(logger.isDebugEnabled())
            logger.debug("Normalized User = " + user);
        return user;
    }
557459
def _normalize_string(raw_str):
  
  return " ".join(
      token.strip()
      for token in tokenizer.encode(text_encoder.native_to_unicode(raw_str)))
880080
function normalizeCmd(cmd, options) {
  if (cmd.cmd) {
    options = options || {};
    _.extend(options, cmd);
    cmd = options.cmd;
    delete options.cmd;
  }
  if (typeof(cmd) === 'string') {
    cmd = {
      command: cmd
    };
  }
  if (typeof(cmd.args) === 'undefined') {
    cmd.args = shellParse(cmd.command);
    cmd.command = cmd.args.shift();
  }
  return cmd;
}
243822
private String normalize(final String viewName) {
		String normalized = viewName;

		if (normalized.startsWith("/")) {
			normalized = normalized.substring(0);
		}

		if (normalized.endsWith("/")) {
			normalized = normalized.substring(0, normalized.length() - 1);
		}

		return normalized.replaceAll("/", ".");
	}
107476
public static String normalize(final String s) {
        if (s == null || s.trim().isEmpty()) {
            return "unspecific";
        }
        return s.replace(':', '/')
                .replace('=', '-')
                .replace(',', '|')
                .replace("\"", "")
                .replace('#', '-');
    }
300780
protected function normalizeNumberOption(array &$options)
    {
        if (isset($options['in'])) {
            if (
                is_array($options['in']) &&
                isset($options['in'][0]) &&
                isset($options['in'][1])
            ) {
                list($options['min'], $options['max']) = $options['in'];
            }
            unset($options['in']);
        }
    }
990188
private String normalise(String str) {
		str = str.replaceAll("\\s+", " ");
		str = tc.toSimp(str);
		str = ChineseTrans.toHalfWidth(str);
		return str;
	}
711975
public static String normalize(final String uri) {
        String normalizedUri = null;
        if (uri != null) {
            normalizedUri = uri; // TODO THIS HAS TO BE IMPLEMENTED
        }
        return normalizedUri;
    }
1169756
function normalize_src(src, options) {
    return '\ufeff' + update_srcmap_namespace(src, options)
        .replace(/^\ufeff/gm, '')    // remove bom
        .replace(/\t/gm, '    ')
        .replace(/\r\n/gm, '\n')
    ;
}