/* (non-Javadoc)
@see groovy.lang.MetaClass#getAttribute(java.lang.Object, java.lang.String)
332429
public Object getAttribute(Object object, String attribute) {
        return delegate.getAttribute(object, attribute);
    }
1098732
@Override
    public Object getAttribute(String name) {
        Object value = this.attributes.get(name);
        if (null == value && null != this.connection.getSSLContext()) {
            // special case logic for SSL based connections
            if (PEER_CERTS.equals(name)
                || SERVLET_CERTS.equals(name)) {
                value = getPeerCertificates();
            } else if (CIPHER_SUITE.equals(name)) {
                value = getCipherSuite();
            } else if (SSL_SESSION.equals(name)) {
                value = this.connection.getSSLContext().getSession();
            }
        }
        return value;
    }
500045
public Object getAttribute(String key) {
		Object result;
		if (attributes == null) {
			result = null;
		} else {
			result = attributes.get(key);
		}
		return result;
	}
755985
public String getAttribute(String attributeName, String defaultValue)
	{
        String result = defaultValue;
        if (m_attributeList!=null)
        {
            result = (String)m_attributeList.get(attributeName);
            if (result==null)
            {
                result = defaultValue;
            }
        }
        return result;
	}
469399
public <T> T getAttribute(String key, Class<T> clazz) {
        return (T) getAttribute(key);
    }
630367
public Object getAttribute(ObjectName name, String attributeName) throws Exception {
		checkClientConnected();
		return mbeanConn.getAttribute(name, attributeName);
	}
1013928
public Object getAttribute(String domain, String beanName, String attributeName) throws Exception {
		return getAttribute(ObjectNameUtil.makeObjectName(domain, beanName), attributeName);
	}
1153409
public Attribute getAttribute(final String attributeName) {
		final Attribute a = attributes.get(attributeName);
		if (a == null)
			throw new IllegalArgumentException("Attribute " + attributeName + " doesn't exists");
		return a;
	}
60724
@Override
    public synchronized Object getAttribute(Object name) {
        if (com.ibm.ejs.ras.TraceComponent.isAnyTracingEnabled() && LoggingUtil.SESSION_LOGGER_CORE.isLoggable(Level.FINER)) {
            String s = name + appNameAndIdString;
            LoggingUtil.SESSION_LOGGER_CORE.entering(methodClassName, methodNames[GET_ATTRIBUTE], s);
        }
        Object o = _attributes.get(name);
        if (com.ibm.ejs.ras.TraceComponent.isAnyTracingEnabled() && LoggingUtil.SESSION_LOGGER_CORE.isLoggable(Level.FINE)) {
            if (!SessionManagerConfig.isHideSessionValues()) {
                LoggingUtil.SESSION_LOGGER_CORE.exiting(methodClassName, methodNames[GET_ATTRIBUTE], o);
            } else {
                LoggingUtil.SESSION_LOGGER_CORE.exiting(methodClassName, methodNames[GET_ATTRIBUTE]);
            }
        }
        return o;
    }
254992
static String getAttributeValue(Element element, String name) {
        Attr attribute = element.getAttributeNode(name);
        if (attribute == null) {
            return null;
        } else {
            return attribute.getValue();
        }
    }
74824
@SuppressWarnings("unchecked")
    public static <T> Optional<T> getAnnotationAttribute(final Annotation anno, final String attrName, final Class<T> attrType) {
        
        try {
            final Method method = anno.annotationType().getMethod(attrName);
            method.setAccessible(true);
            if(!attrType.equals(method.getReturnType())) {
                return Optional.empty();
            }
            
            final Object value = method.invoke(anno);
            return Optional.of((T)value);
            
        } catch (Exception e) {
            return Optional.empty();
        }
        
    }
785293
@Override
    public Object getAttribute(String name) {
        if (name.startsWith(IPortletRenderer.RENDERER_ATTRIBUTE_PREFIX)) {
            return null;
        }

        final Object attribute = this.attributes.get(name);
        if (attribute != null) {
            return attribute;
        }

        if (name.startsWith(AbstractHttpServletRequestWrapper.PORTAL_ATTRIBUTE_PREFIX)) {
            Object result = this.servletRequest.getAttribute(name);
            return result;
        }

        if (name.equals(PortletRequest.RENDER_PART)) {
            Object result = this.servletRequest.getAttribute(name);
            return result;
        }

        return this.requestAttributeService.getAttribute(
                this.servletRequest, portletWindow.getPlutoPortletWindow(), name);
    }
705912
public String getAttributeString(ObjectName name, String attributeName) throws Exception {
		Object bean = getAttribute(name, attributeName);
		if (bean == null) {
			return null;
		} else {
			return ClientUtils.valueToString(bean);
		}
	}
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;
    }
775490
public Object getAttribute(File file, String attribute) {
    String view = getViewName(attribute);
    String attr = getSingleAttribute(attribute);
    return getAttribute(file, view, attr);
  }
438518
public static String getAttributeValue(final Element element, final String name) {
        final Node node = element.getAttributes().getNamedItem(name);
        if (node != null) {
            return node.getNodeValue();
        }

        return null;
    }
151129
@Override
	public Object getFwkAttribute(final String name) {
		if (attribMap == null) {
			return null;
		}
		return attribMap.get(name);
	}