Appends the elements in other_array to self, as standardized URL Hashes
341786
def concat(urls)
      if !urls.nil?
        converted = urls.map { |url| convert_remote_url( url ) }
        super(converted)
      else
        super(nil)
      end 
    end
1052462
def build_self_uri_list(self_uri_list):
    ""
    uri_list = []
    for self_uri in self_uri_list:
        uri = ea.Uri()
        utils.set_attr_if_value(uri, 'xlink_href', self_uri.get('xlink_href'))
        utils.set_attr_if_value(uri, 'content_type', self_uri.get('content-type'))
        uri_list.append(uri)
    return uri_list
623017
def add_transition_array(rel, array_of_hashes)
      array_of_hashes.reduce(RepresentorBuilder.new(@representor_hash)) do |memo, transition|
        transition = symbolize_keys(transition)
        href = transition.delete(:href)
        memo = memo.add_transition(rel, href, transition)
      end
    end
1266735
function insert(arr, rest_items) {
        var diff = difference(slice(arguments, 1), arr);
        if (diff.length) {
            Array.prototype.push.apply(arr, diff);
        }
        return arr.length;
    }
748997
def merge(other)
      old_attributes = attributes
      other_attributes = other.is_a?(Hash) ? other : other.attributes

      old_attributes.merge!(other_attributes) do |key, old_value, new_value|
        case key
        when :clusters, :contexts, :users
          old_value + new_value.reject do |new_mapping|
            old_value.any? { |old_mapping| old_mapping[:name] == new_mapping[:name] }
          end
        else
          case old_value
          when Array
            (old_value + new_value).uniq
          when Hash
            old_value.merge(new_value) do |_key, inner_old_value, inner_new_value|
              inner_old_value.nil? ? inner_new_value : inner_old_value
            end
          when NilClass
            new_value
          else
            warn "key is #{key} old val is #{old_value.inspect} and new val is #{new_value.inspect}"
            old_value
          end
        end
      end

      self.class.new(old_attributes)
    end
122269
function _collectURLs ( token ) {

        var elem, isArrayElem;

        if ( Array.isArray( token ) ) {

            for ( var i = 0; i < token.length; i++ ) {

                elem = token[ i ];
                isArrayElem = Array.isArray( elem );

                if ( isArrayElem && ( elem[ 0 ] === 'uri' ) ) {

                    urls.push( elem );

                } else if ( isArrayElem ) {

                    _collectURLs( elem );

                }

            }

        }

    }
90231
function(older_hash, newer_hash){

	if( ! older_hash ){ older_hash = {}; }
	if( ! newer_hash ){ newer_hash = {}; }

	var ret_hash = {};
	function _add (val, key){
	    ret_hash[key] = val;
	}
	each(older_hash, _add);
	each(newer_hash, _add);
	return ret_hash;
    }
762191
def merge!(other)
      @hooks.merge!(other.dup.hooks) do |key, array, other_array|
        temp_hash, output = {}, []

        (array + other_array).reverse_each do |pair|
          temp_hash[pair.first] ||= output.unshift(pair)
        end

        output
      end

      self
    end
986515
def append(self, *other):
    
    self._data = it.chain(self._data, Stream(*other)._data)
    return self
1159644
function setUrlHashParameters(params) {

  var keys = Object.keys(params);
  var values = Object.values(params);
  var pairs = [];
  keys.forEach(function(key, i) {
    if (key != '') pairs.push(keys[i] + '=' + values[i]);
  });
  var hash = pairs.join('&');
  window.location.hash = hash;

}
725201
def to_hash
      {}.merge(@properties).tap do |h|
        h['_links'] = {}.merge @links    unless @links.empty?

        combined_embedded = {}
        combined_embedded.merge! @embedded unless @embedded.empty?
        combined_embedded.merge! @embedded_arrays unless @embedded_arrays.empty?
        h['_embedded'] = combined_embedded unless combined_embedded.empty?
      end
    end
161262
def update(other_hash)
      if other_hash.is_a? Hash
        super(other_hash)
      else
        other_hash.to_hash.each_pair do |key, value|
          if block_given?
            value = yield(key, value)
          end
          self[key] = value
        end
        self
      end
    end
849597
def render_alternate(tags)
      alternate = meta_tags.extract(:alternate)
      return unless alternate

      if alternate.kind_of?(Hash)
        alternate.each do |hreflang, href|
          tags << Tag.new(:link, rel: 'alternate', href: href, hreflang: hreflang) if href.present?
        end
      elsif alternate.kind_of?(Array)
        alternate.each do |link_params|
          tags << Tag.new(:link, { rel: 'alternate' }.with_indifferent_access.merge(link_params))
        end
      end
    end
1349197
def shallow_update(other_hash)
      other_hash.each_pair do |k, v|
        regular_writer(convert_key(k), convert_value(v, true))
      end
      self
    end
953029
def wrap_in_array(object)
      if object.nil?
        []
      elsif object.respond_to?(:to_ary)
        object.to_ary || [object]
      else
        [object]
      end
    end
304338
function urlJoin() {
    var args = Array.prototype.slice.call(arguments),
        prefixDoubleSlash = false,
        url;

    // Remove empty item at the beginning
    if (args[0] === '') {
        args.shift();
    }

    // Handle schemeless protocols
    if (args[0].indexOf('//') === 0) {
        prefixDoubleSlash = true;
    }

    // join the elements using a slash
    url = args.join('/');

    // Fix multiple slashes
    url = url.replace(/(^|[^:])\/\/+/g, '$1/');

    // Put the double slash back at the beginning if this was a schemeless protocol
    if (prefixDoubleSlash) {
        url = url.replace(/^\//, '//');
    }

    url = deduplicateSubDir(url);
    return url;
}
910208
def _combine_hash_arrays(arrays, num_items):
    
    try:
        first = next(arrays)
    except StopIteration:
        return np.array([], dtype=np.uint64)

    arrays = itertools.chain([first], arrays)

    mult = np.uint64(1000003)
    out = np.zeros_like(first) + np.uint64(0x345678)
    for i, a in enumerate(arrays):
        inverse_i = num_items - i
        out ^= a
        out *= mult
        mult += np.uint64(82520 + inverse_i + inverse_i)
    assert i + 1 == num_items, 'Fed in wrong num_items'
    out += np.uint64(97531)
    return out