Java XML Attribute Read readBoolAttr(Element element, String attributeName)

Here you can find the source of readBoolAttr(Element element, String attributeName)

Description

read Bool Attr

License

Open Source License

Declaration

public static boolean readBoolAttr(Element element, String attributeName) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import org.w3c.dom.Element;

public class Main {
    public static boolean readBoolAttr(Element element, String attributeName) {
        String attributeValue = element.getAttribute(attributeName);
        return Boolean.parseBoolean(attributeValue);
    }//  w  w w. ja va 2s. c  o  m
}

Related

  1. getOptionalAttribute(Element elt, String name)
  2. getOptionalAttributeValue(NamedNodeMap attrs, String name)
  3. readAttribute(Node element, String attributeName)
  4. readAttribute(Node node, String attribute, String defaultValue)
  5. readAttributeWithPrefix(Node node, String attributePrefix, String defaultValue)
  6. readBooleanAttribute(Element elem, String name, boolean defaultValue)
  7. readBooleanAttributeElement(final XMLStreamReader reader, final String attributeName)
  8. readFloat(Node node, String attributeName, float def)
  9. readFloatAttribute(XMLStreamReader reader, String attributeName)