public static <T extends XmlAttribute> XmlAttributeValuePattern xmlAttributeValue(ElementPattern<T> attributePattern) {
    for (PatternCondition<? super T> condition : attributePattern.getCondition().getConditions()) {
      if (condition instanceof PsiNamePatternCondition && "withLocalName".equals(condition.getDebugMethodName())) {
        return xmlAttributeValue().withLocalName(((PsiNamePatternCondition<?>)condition).getNamePattern()).withParent(attributePattern);
      }
    }

    return xmlAttributeValue().withParent(attributePattern);
  }
public static <T extends XmlAttribute> XmlAttributeValuePattern xmlAttributeValue(ElementPattern<T> attributePattern)