public static boolean isVariable(@NotNull XmlAttribute attribute) {
    return isXsltNameAttribute(attribute) && isVariable(attribute.getParent());
  }
public static boolean isVariable(@NotNull XmlAttribute attribute)