Get value of specified data attribute
551769
function getData(el, attr, isInt, prefix) {
    if (prefix === undefined) {
      prefix = 'wookmark-';
    }
    var val = el.getAttribute('data-' + prefix + attr);
    if (isInt === true) {
      return parseInt(val, 10);
    }
    return val;
  }
69364
public String getValue(String name)
  {
    Attr attr = ((Attr) m_attrs.getNamedItem(name));
    return (null != attr) 
          ? attr.getValue() : null;
  }
25554
def getstr_data(self, name, vals):
        """"""
        fld2val = self.get_fld2val(name, vals)
        return self.fmt.format(**fld2val)
1058427
function(node) {
        var attributes = {};
        var i, len, data, key;
        var dataNodes = node.getElementsByTagName("Data");
        for (i = 0, len = dataNodes.length; i < len; i++) {
            data = dataNodes[i];
            key = data.getAttribute("name");
            var ed = {};
            var valueNode = data.getElementsByTagName("value");
            if (valueNode.length) {
                ed['value'] = this.getChildValue(valueNode[0]);
            }
            if (this.kvpAttributes) {
                attributes[key] = ed['value'];
            } else {
                var nameNode = data.getElementsByTagName("displayName");
                if (nameNode.length) {
                    ed['displayName'] = this.getChildValue(nameNode[0]);
                }
                attributes[key] = ed;
            } 
        }
        var simpleDataNodes = node.getElementsByTagName("SimpleData");
        for (i = 0, len = simpleDataNodes.length; i < len; i++) {
            var ed = {};
            data = simpleDataNodes[i];
            key = data.getAttribute("name");
            ed['value'] = this.getChildValue(data);
            if (this.kvpAttributes) {
                attributes[key] = ed['value'];
            } else {
                ed['displayName'] = key;
                attributes[key] = ed;
            }
        }
        
        return attributes;    
    }
940905
public String getAttribute(String name, String def) {
		String value = dom.getAttribute(name);
		if ((value == null) || (value.length() == 0)) {
			return def;
		}
		
		return value;
	}
747873
public Object getValue(String attributeName) {
        if (attributeName != null) {
            return values.get(attributeName);
        }
        return null;
    }
825267
def getAttribute(self, attrName, defaultValue=None):
        '''
            
        '''

        if attrName in TAG_ITEM_BINARY_ATTRIBUTES:
            if attrName in self._attributes:
                attrVal = self._attributes[attrName]
                if not attrVal:
                    return True # Empty valued binary attribute

                return attrVal # optionally-valued binary attribute
            else:
                return False
        else:
            return self._attributes.get(attrName, defaultValue)
473222
function getDefAttrVal(self, name) {
        var attrs = self.getAttrs(), attrConfig = ensureNonEmpty(attrs, name, 1), valFn = attrConfig.valueFn, val;
        if (valFn && (valFn = normalFn(self, valFn))) {
            val = valFn.call(self);
            if (val !== undefined) {
                attrConfig.value = val;
            }
            delete attrConfig.valueFn;
            attrs[name] = attrConfig;
        }
        return attrConfig.value;
    }
640734
@Api
	public void getValue(String name, StringAttribute attribute) {
		attribute.setValue((String) formWidget.getValue(name));
	}
120346
public String getString(Map<String, Object> data, String attr) {
    Object value = data.get(attr);
    if (null == value) { return null; }
    if (!value.getClass().isArray()) { return value.toString(); }
    String[] values = (String[]) value;
    if (values.length == 1) {
      return values[0];
    } else {
      return Strings.join(values, ",");
    }
  }
1248416
function getData(element, name) {
  if (isObject(element[name])) {
    return element[name];
  } else if (element.dataset) {
    return element.dataset[name];
  }

  return element.getAttribute('data-' + hyphenate(name));
}
1237038
@Override
    public String getValue() {
        String value = attrMixin.getAttribute(VALUE);
        return value.isEmpty() ? getText() : value;
    }
1311167
@Api
	public void getValue(String name, IntegerAttribute attribute) {
		attribute.setValue(toInteger(formWidget.getValue(name)));
	}
154346
def getdata(self, tree, location, force_string=False):
        """"""
        found = tree.xpath('%s/text()' % location)
        if not found:
            return None
        else:
            data = found[0]
        if force_string:
            return data
        if data == 'True':
            return True
        elif data == 'False':
            return False
        else:
            try:
                return int(data)
            except ValueError:
                try:
                    return float(data)
                except ValueError:
                    # It's a string
                    return data
1007549
def pickdata(self, data):
        
        """
        attrs = data.get(self.__options['attrkey']) or {}
        values = data.get(self.__options['valuekey']) or ''
        return (attrs, values)
744326
def getValueFromValue(value):
    
    if type(value) != common.AttributeValue:
        raise TypeError(
            "Expected an AttributeValue, but got {}".format(type(value)))
    if value.WhichOneof("value") is None:
        raise AttributeError("Nothing set for {}".format(value))
    return getattr(value, value.WhichOneof("value"))
641784
def get_value(self, node):
        """"""
        if not isinstance(node, ast.Attribute):
            raise TypeError("must be an attribute")

        if node.value.id != self.choices.__name__:
            raise TypeError("must be an attribute of {}".format(self.choices.__name__))

        return getattr(self.choices, node.attr)