/*
Throw NPE if name is null

@see com.ibm.ws.webcontainer.webapp.WebApp#getAttribute(java.lang.String)
519831
@Override
    public Object getAttribute(String name) {
        if (name == null) {
            logger.logp(Level.SEVERE, CLASS_NAME, "getAttribute", servlet40NLS.getString("name.is.null"));
            throw new java.lang.NullPointerException(servlet40NLS.getString("name.is.null"));
        }

        return super.getAttribute(name);
    }
1005702
public Object getAttribute(String key) {
        if (attributes != null && !attributes.isEmpty()) {
            return attributes.get(key);
        }
        return null;
    }
246949
public UnprotectedStringBuffer getAttributeValueByFullName(CharSequence name) {
		for (Attribute attr : event.attributes)
			if (attr.text.equals(name))
				return attr.value;
		return null;
	}
238868
public Attribute getAttributeByOriginalName(String name) {
		for (Attribute a : attributes)
			if (name.equals(a.getOriginalName()))
				return a;
		return null;
	}
500045
public Object getAttribute(String key) {
		Object result;
		if (attributes == null) {
			result = null;
		} else {
			result = attributes.get(key);
		}
		return result;
	}
1271097
@SuppressWarnings("unchecked")
	public <T> T getAttribute(String name) {
		return (T) this.webSocketSession.getAttributes().get(name);
	}
254992
static String getAttributeValue(Element element, String name) {
        Attr attribute = element.getAttributeNode(name);
        if (attribute == null) {
            return null;
        } else {
            return attribute.getValue();
        }
    }
741531
@Nullable
    public String getString(String name) {
        Attribute attribute = get(name);
        if (attribute == null) {
            return null;
        }
        return attribute.getValue();
    }
444798
public Object getAttribute(String name)
    {
        if (_attributes==null)
            return null;
        return _attributes.get(name);
    }
389878
@Override
    public synchronized Object getAttribute(String name) {
	if (disconnected) return disconnectData.attributes.get(name);
	return req.getAttribute(name);
    }
823336
@Override
    public String getAttribute(final String name) {
        String value;
        value = hash.get(name);
        return value;
    }
940070
public Object getAttributeValue(String name) throws IOException {
        ObjectIdentifier oid = PKCS9Attribute.getOID(name);

        if (oid == null)
            throw new IOException("Attribute name " + name +
                                  " not recognized or not supported.");

        return getAttributeValue(oid);
    }
1187821
@Override
    public Object getAttribute(String name, Object value) {
        log.debug("getAttribute - name: {} value: {}", name, value);
        Object result = null;
        if (name != null) {
            result = attributes.putIfAbsent(name, value);
            if (result == null) {
                // no previous value
                modified.set(true);
                final SharedObjectEvent event = new SharedObjectEvent(Type.CLIENT_UPDATE_DATA, name, value);
                if (ownerMessage.addEvent(event) && syncEvents.add(event)) {
                    notifyModified();
                    changeStats.incrementAndGet();
                }
                result = value;
            }
        }
        return result;
    }
1316514
public static Object getAttribute(String name)
  {
    ClassLoader loader = Thread.currentThread().getContextClassLoader();

    return getAttribute(name, loader);
  }
45696
public Attribute getAttribute(String name)
  {
    ArrayList<Attribute> attributeList = getAttributeList();
    
    for (int i = attributeList.size() - 1; i >= 0; i--) {
      Attribute attr = attributeList.get(i);

      if (attr.getName().equals(name))
        return attr;
    }

    return null;
  }
1280714
@Override
    public Attribute<? super X, ?> getAttribute(String paramName)
    {
        Attribute<? super X, ?> attribute = getDeclaredAttribute(paramName, false);
        if (attribute == null && superClazzType != null)
        {
            attribute = superClazzType.getAttribute(paramName);
        }

        checkForValid(paramName, attribute);
        return attribute;

    }
978488
@Override
    public Object getAttributeValue(final String name) {
        for (final IAdditionalDescriptors additionalDescriptors : delegateDescriptors) {
            final Map<String, List<Object>> attributes = additionalDescriptors.getAttributes();
            if (attributes != null && attributes.containsKey(name)) {
                return additionalDescriptors.getAttributeValue(name);
            }
        }

        return null;
    }