Get the attribute have enabled value
Form android styles namespace

@param attrs        AttributeSet
@param attribute    The attribute to retrieve
@param defaultValue What to return if the attribute isn't found
@return Resulting value
4595
public static boolean isTrueFromAttribute(AttributeSet attrs, String attribute, boolean defaultValue) {
        return attrs.getAttributeBooleanValue(Ui.androidStyleNameSpace, attribute, defaultValue);
    }
751608
public int getAttributeAsInt(AnnotationAttributeType attribute) {
		String temp = attributes.get(attribute.getValue());

		return Integer.parseInt(temp);
	}
776593
public String getAttributeValue(final String name) {
        final List<Attribute> attributes = Collections.synchronizedList(getAttributes());
        for (int i = 0; i < attributes.size(); i++) {
            final Attribute a = attributes.get(i);

            if (a.getName() != null && a.getName().equals(name)) {
                return a.getValue();
            }
        }
        return null;
    }
714969
protected static boolean locateMatchingAttributeValue(final String attrName, final String attrValue,
                                                          final Map<String, List<Object>> attributes) {
        return locateMatchingAttributeValue(attrName, attrValue, attributes, true);
    }
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;
	}
1114971
@Override
	public boolean isAttributePresent(String attributeName) throws WidgetException {
		try {
			WebElement webElement = null;
			String attrValue = null;

			// WebDriver get attribute
			try {
				webElement = findElement();
				attrValue = webElement.getAttribute(attributeName);
				highlight(HIGHLIGHT_MODES.GET);
			} catch (Exception e) {
				throw new RuntimeException("Exception happened at locator: " + locator + " attribute: " + attributeName + e.getMessage());
			}

			if (attrValue != null) {
				return true;
			}

			return false;
		} catch (Exception e) {
			throw new WidgetException("Error while determining if attribute is present: " + attributeName, locator, e);
		}
	}
217459
public boolean apply(String attribute) {
		if (attribute == null || value == null) {
			return true;
		}

		String attNoAccents = StringUtils.stripAccents(attribute);
		String valueNoAccents = StringUtils.stripAccents(value);
		return StringUtils.containsIgnoreCase(attNoAccents, valueNoAccents);
	}
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);
    }
830370
private String getNodeStringDefault(String defaultValue, String attribute, String... path)
    {
        final Xml node = getNodeDefault(path);
        if (node != null && node.hasAttribute(attribute))
        {
            return node.readString(attribute);
        }
        return defaultValue;
    }
616612
public final boolean getBooleanDefault(boolean defaultValue, String attribute, String... path)
    {
        return Boolean.parseBoolean(getNodeStringDefault(String.valueOf(defaultValue), attribute, path));
    }
643974
public <T> T get(String attr, Object defaultValue) {
		Object result = attrs.get(attr);
		return (T)(result != null ? result : defaultValue);
	}
261155
private Object getUnconfiguredAttributeValue(EvaluationContext context, ExtendedAttributeDefinition attributeDef) throws ConfigEvaluatorException {

        Object rawValue = null;

        // no value in config then try ibm:variable if set

        rawValue = variableEvaluator.lookupVariableExtension(context, attributeDef);

        // no value in config, no ibm:variable, try defaults
        if (rawValue == null) {
            String[] defaultValues = attributeDef.getDefaultValue();
            if (defaultValues != null) {
                rawValue = Arrays.asList(defaultValues);
            }
        }

        return rawValue;
    }
1350452
private void parseAttributes(Context context, AttributeSet attrs, int defStyle){
        int defaultColor = context.getResources().getColor(R.color.black26);
        final TypedArray a = context.obtainStyledAttributes(attrs,
                R.styleable.EmptyView, defStyle, 0);
        if (a == null) {
            mEmptyMessageColor = defaultColor;
            mEmptyActionColor = defaultColor;
            mEmptyMessageTextSize = (int) SizeUtils.dpToPx(context, 18);
            mEmptyActionTextSize = (int) SizeUtils.dpToPx(context, 14);
            mEmptyMessageTypeface = Face.ROBOTO_REGULAR;
            mEmptyIconPadding = getResources().getDimensionPixelSize(R.dimen.activity_padding);
            return;
        }

        // Parse attributes
        mEmptyIcon = a.getResourceId(R.styleable.EmptyView_emptyIcon, -1);
        mEmptyIconSize = a.getDimensionPixelSize(R.styleable.EmptyView_emptyIconSize, -1);
        mEmptyIconColor = a.getColor(R.styleable.EmptyView_emptyIconColor, defaultColor);
        mEmptyIconPadding = a.getDimensionPixelSize(R.styleable.EmptyView_emptyIconPadding, getResources().getDimensionPixelSize(R.dimen.activity_padding));

        mEmptyMessage = a.getString(R.styleable.EmptyView_emptyMessage);
        mEmptyMessageColor = a.getColor(R.styleable.EmptyView_emptyMessageColor, defaultColor);
        int typeface = a.getInt(R.styleable.EmptyView_emptyMessageTypeface, 0);
        mEmptyMessageTypeface = MessageTypeface.from(typeface).getTypeface();
        mEmptyMessageTextSize = a.getDimensionPixelSize(R.styleable.EmptyView_emptyMessageTextSize,
                (int) SizeUtils.dpToPx(context, 18));

        mEmptyActionColor = a.getColor(R.styleable.EmptyView_emptyActionColor, defaultColor);
        mEmptyActionText = a.getString(R.styleable.EmptyView_emptyActionText);
        mEmptyActionTextSize = a.getDimensionPixelSize(R.styleable.EmptyView_emptyActionTextSize,
                (int) SizeUtils.dpToPx(context, 14));

        mState = a.getInt(R.styleable.EmptyView_emptyState, STATE_EMPTY);

        a.recycle();
    }
1322058
public String getAttributeNS(String namespaceURI, String localName)
  {

    error(XMLErrorResources.ER_FUNCTION_NOT_SUPPORTED);  //"getAttributeNS not supported!");

    return null;
  }
120317
public String getAttribute(String attributeName) {
		if (attributeName != null){
			return this.attributes.get(attributeName);
		}
		
		return null;
	}
1252247
public List<Attribute> getDefaultAttributes(String localName, String namespace) {
    if (defaultValuesCollector != null) {
      return defaultValuesCollector.getDefaultAttributes(localName, namespace);
    }
    return null;
  }
288982
public function getAttribute( string $name, $defaultValue = false )
   {

      if ( ! $this->hasAttribute( $name ) )
      {
         return $defaultValue;
      }

      return $this->_attributes[ $name ];

   }