System.Runtime.Serialization.ExtensionDataReader.GetAttribute C# (CSharp) Method

GetAttribute() public method

public GetAttribute ( string name, string namespaceURI ) : string
name string
namespaceURI string
return string
        public override string GetAttribute(string name, string namespaceURI)
        {
            if (IsXmlDataNode)
                return _xmlNodeReader.GetAttribute(name, namespaceURI);

            for (int i = 0; i < _element.attributeCount; i++)
            {
                AttributeData attribute = _element.attributes[i];
                if (attribute.localName == name && attribute.ns == namespaceURI)
                    return attribute.value;
            }

            return null;
        }

Same methods

ExtensionDataReader::GetAttribute ( int i ) : string
ExtensionDataReader::GetAttribute ( string name ) : string