attribute definitions
778054
function (obj, prop) { // simple version
    if (obj.currentStyle) return obj.currentStyle[prop];
    else if (window.getComputedStyle) return document.defaultView.getComputedStyle(obj, null).getPropertyValue(prop);
  }
203606
function _setAttributes(el, attrs) {
  Object.keys(attrs).forEach((key) => {
    el.setAttribute(key, attrs[key]);
  });
}
316917
def attribute?(attr)
      return false unless container.key?(key_as_sym(attr))
      ![ "", " ", nil, [],[""], [" "], self.class.new({}), [[]]].any? {|a| a == container[key_as_sym(attr)] }
    end
1141775
function Attribute(a, b) {
	    _classCallCheck(this, Attribute);

	    if (typeof a === 'object' && typeof a.type === 'string' && typeof a.value === 'string') {
	      b = a.value;
	      a = a.type;
	    }
	    if (typeof a !== 'string') {
	      throw new Error('First param must be a string, got ' + (typeof a === 'undefined' ? 'undefined' : _typeof(a)) + ': ' + _JSON$stringify(a));
	    }
	    if (!a.length) {
	      throw new Error('First param string is empty');
	    }
	    if (b) {
	      if (typeof b !== 'string') {
	        throw new Error('Second parameter must be a string, got ' + (typeof b === 'undefined' ? 'undefined' : _typeof(b)) + ': ' + _JSON$stringify(b));
	      }
	      if (!b.length) {
	        throw new Error('Second param string is empty');
	      }
	      this.type = a;
	      this.value = b;
	    } else {
	      this.value = a;
	      var t = Attribute.guessTypeOf(this.value);
	      if (t) {
	        this.type = t;
	      } else {
	        throw new Error('Type of attribute was omitted and could not be guessed');
	      }
	    }
	  }
1161769
public void setAttribute(String attrname, String value) {
        if (attributes == null)
            attributes = new ArrayList<Attribute>();
        Attribute.setAttribute(attributes, attrname, value);
    }
294353
def attribute(name, options = {})
        return unless
          @_object &&
          attribute_present?(name) &&
          resolve_condition(options)

        attribute = data_object_attribute(name)
        name = create_key(options[:as] || name)
        @_result[name] = attribute
      end
164369
def attributes!(object, *attrs)
      attrs.each do |attr|
        method_missing attr, object.send(attr)
      end
    end
1196392
function(options) {
      var attrs = options.attributes;
      if (_.isFunction(attrs)) {
        attrs = attrs();
      }
      if (_.isArray(attrs)) {
        return attrs;
      }
    }
404711
def attributes(self):
        
        length = c_bst_ulong()
        sarr = ctypes.POINTER(ctypes.c_char_p)()
        _check_call(_LIB.XGBoosterGetAttrNames(self.handle,
                                               ctypes.byref(length),
                                               ctypes.byref(sarr)))
        attr_names = from_cstr_to_pystr(sarr, length)
        return {n: self.attr(n) for n in attr_names}
704263
private void mapAttributes(List<Attribute> input, Map<String, List<Attribute>> output) {
        Iterator<Attribute> it = input.iterator();
        while (it.hasNext()) {
            Attribute attr = it.next();
            String id = attr.getId().toString();

            if (output.containsKey(id)) {
                List<Attribute> list = output.get(id);
                list.add(attr);
            } else {
                List list = new ArrayList<Attribute>();
                list.add(attr);
                output.put(id, list);
            }
        }
    }
464045
def attribute(*args)
      node = Nodes::Attribute.new

      if args.first.is_a?(Hash)
        args.first.each_pair { |k, v| node[v] = k }
      else
        options = args.extract_options!
        args.each { |name|
          key = options[:as] || name
          node[key] = name
        }
        node.condition = options[:if]
      end

      @template.add_node node
    end
1195012
def attribute(func):
    """"""
    attr = abc.abstractmethod(func)
    attr.__iattribute__ = True
    attr = _property(attr)
    return attr
884546
function getAllAttributes() {
  return _.reduce(
    this.getInheritanceChain(),
    (acc, cls) => _.reduce(cls.attributes, (acc2, v, k) => {acc2[k] = v; return acc2}, acc),
    {})
}
131719
void setAttribute(File file, String attribute, Object value) {
    state.checkOpen();
    // TODO(cgdecker): Change attribute stuff to avoid the sad boolean parameter
    attributes.setAttribute(file, attribute, value, false);
  }
374134
private void extractAttributes(String attributes)
	{
		String s = attributes.trim();
		if (s.length() > 0 && s.charAt(s.length() - 1) == '/')
			elem.setEmptyElementTag(true);

		while (s.length() != 0) {
			final int equal = s.indexOf('=');
			if (equal == -1 || equal == s.length() - 1)
				break;
			// cut off attribute name
			final String att = s.substring(0, equal).trim();
			s = s.substring(equal + 1).trim();
			if (s.length() == 0)
				break;
			final boolean quote = s.charAt(0) == '\'' || s.charAt(0) == '\"';
			if (att.length() > 0 && quote) {
				String value = s.substring(1);
				final int end = value.indexOf(s.charAt(0));
				if (end >= 0)
					value = value.substring(0, end);
				elem
					.addAttribute(new Attribute(att, References.replace(value, false)));
			}
			final int i = s.indexOf(quote ? s.charAt(0) : ' ', 1);
			s = i == -1 ? "" : s.substring(i + 1);
		}
	}
407343
def set_attributes(d, elm):
    """"""
    for key in d:
        elm.setAttribute(key, d[key])
81117
private void appendAttribute(Appendable buf, String attrName, String encodedValue) throws IOException {
        buf.append(' ').append(attrName).append('=').append('\"').append(encodedValue).append('\"');
    }