Normalizes the tag name. Actually, capitalizes the given name.
If the given tag is null, returns the default from options
19563
function tagName(tag, options) {
  if (tag == null || tag === '') {
    tag = options.defaultTag || 'Api';
  }
  tag = toIdentifier(tag);
  return tag.charAt(0).toUpperCase() + (tag.length == 1 ? '' : tag.substr(1));
}
701185
def tag(name, tag_name):
    

    with LOCK:
        # just to check if <name> exists
        metric(name)

        TAGS.setdefault(tag_name, set()).add(name)
752881
public void removeTag(String name) {
        XtraTag tag = getTagByName(name);
        if (tag != null) {
            tags.remove(tag);
        }
    }
1360846
public static String capitalize(String name) {
		if (name == null || name.length() == 0) {
			return name;
		}
		return name.substring(0, 1).toUpperCase(ENGLISH) + name.substring(1);
	}
281077
function getTag(entry, tagName) {
  var parsed = entry.parsed;
  return _.find(parsed.tags, ['title', tagName]) || null;
}
843620
def normalize_header(name)
      return name if name =~ CANONICAL_NAME_RE

      normalized = name.split(/[\-_]/).each(&:capitalize!).join("-")

      return normalized if normalized =~ COMPLIANT_NAME_RE

      raise HeaderError, "Invalid HTTP header field name: #{name.inspect}"
    end
1006468
def render_with_normalization(tags, name)
      value = TextNormalizer.public_send("normalize_#{name}", meta_tags.extract(name))
      normalized_meta_tags[name] = value
      tags << Tag.new(:meta, name: name, content: value) if value.present?
    end
223731
private static String normalizeDirName(String name)
    {
        if(name == null)
            return null;
        return name.toLowerCase().replaceAll("[^a-zA-Z0-9]", "-");
    }
598145
@CheckReturnValue
  Context transitionToTagName(HtmlTagNode node) {
    // according to spec ascii case is not meaningful for tag names.
    String tagName = node.getTagName().getStaticTagNameAsLowerCase();
    boolean isEndTag = state == HtmlContext.HTML_BEFORE_CLOSE_TAG_NAME;
    Context.ElementType elType = ElementType.NORMAL;
    int newTemplateNestDepth = templateNestDepth;
    if (tagName.equals("template")) {
      newTemplateNestDepth += isEndTag ? -1 : 1;
      if (newTemplateNestDepth < 0) {
        throw SoyAutoescapeException.createWithNode(
            "Saw an html5 </template> without encountering <template>.", node);
      }
    } else if (!isEndTag) {
      // We currently only treat <img> and SVG's <image> as a media type, since for <video> and
      // <audio> there are concerns that attackers could introduce rich video or audio that
      // facilitates social engineering.  Upon further review, it's possible we may allow them.
      switch (tagName) {
        case "img":
        case "image":
          elType = ElementType.MEDIA;
          break;
        case "iframe":
          elType = ElementType.IFRAME;
          break;
        case "script":
          elType = ElementType.SCRIPT;
          break;
        case "style":
          elType = ElementType.STYLE;
          break;
        case "base":
          elType = ElementType.BASE;
          break;
        case "link":
          if (node.getDirectAttributeNamed("rel") == null
              && node.getDirectAttributeNamed("itemprop") != null) {
            elType = ElementType.NORMAL;
          } else {
            String rel = getStaticAttributeValue(node, "rel");
            elType =
                rel != null && REGULAR_LINK_PATTERN.matcher(rel).matches()
                    ? ElementType.NORMAL
                    : ElementType.LINK_EXECUTABLE;
          }
          break;
        case "meta":
          String httpEquiv = getStaticAttributeValue(node, "http-equiv");
          elType =
              "refresh".equalsIgnoreCase(httpEquiv) ? ElementType.META_REFRESH : ElementType.NORMAL;
          break;
        case "textarea":
          elType = ElementType.TEXTAREA;
          break;
        case "title":
          elType = ElementType.TITLE;
          break;
        case "xmp":
          elType = ElementType.XMP;
          break;
        default: // fall out
      }
    }
    return toBuilder()
        .withState(HtmlContext.HTML_TAG_NAME)
        .withoutAttrContext()
        .withElType(elType)
        .withTemplateNestDepth(newTemplateNestDepth)
        .build();
  }
1044703
def normalize(cls, name):
        """"""
        name = name.lower() # lower-case
        for _replace in [' ','-','(',')','?']:
            name = name.replace(_replace,'')
        return name
43678
private void initStandardTagsLowercase() {
        Iterator<String> it = standardTags.iterator();
        while (it.hasNext()) {
            standardTagsLowercase.add(StringUtils.toLowerCase(it.next()));
        }
    }
718732
private String getTagValue(String tag, String[] input, String defaultValue) {
		for (String arg : input) {
			Matcher matcher = CommandLineArgs.pattern.matcher(arg);
			// Get tagname and contents of tag
			if (matcher.find()) {
				String tagname = matcher.group(1);
				if (tag.equals(tagname)) {
					return matcher.group(2);
				}
			}
		}
		return defaultValue;
	}
340656
private void checkTagName(String name) {
        if (standardTags.contains(name)) {
            overridenStandardTags.add(name);
        } else {
            if (name.indexOf('.') == -1) {
                potentiallyConflictingTags.add(name);
            }
            unseenCustomTags.add(name);
        }
    }
151737
public static function normalize($name)
	{
		if (!static::isValid($name))
		{
			throw new InvalidArgumentException("Invalid tag name '" . $name . "'");
		}

		// Non-namespaced tags are uppercased
		if (strpos($name, ':') === false)
		{
			$name = strtoupper($name);
		}

		return $name;
	}
447657
function isNullEndTag(tagName) {
  let names = ['br', 'hr', 'img', 'input', 'link', 'meta'];
  tagName = tagName ? tagName.toLowerCase() : '';
  return names.indexOf(tagName) > -1 ? true : false;
}
1336844
function(node, tagName) {
            node = Y.Dom.get(node);
            if (!node) {
                return null;
            }
            var method = function(el) {
                 return el[TAG_NAME] && el[TAG_NAME].toUpperCase() == tagName.toUpperCase();
            };

            return Y.Dom.getAncestorBy(node, method);
        }
952383
public static Id normalize(Id id) {
    return (new DefaultId(id.name())).withTags(id.tags()).normalize();
  }