Moves the caret to the specified index.

@param {int} i
165442
function(i) {
			var self = this;
	
			if (self.settings.mode === 'single') {
				i = self.items.length;
			} else {
				i = Math.max(0, Math.min(self.items.length, i));
			}
	
			if(!self.isPending) {
				// the input must be moved by leaving it in place and moving the
				// siblings, due to the fact that focus cannot be restored once lost
				// on mobile webkit devices
				var j, n, fn, $children, $child;
				$children = self.$control.children(':not(input)');
				for (j = 0, n = $children.length; j < n; j++) {
					$child = $($children[j]).detach();
					if (j <  i) {
						self.$control_input.before($child);
					} else {
						self.$control.append($child);
					}
				}
			}
	
			self.caretPos = i;
		}
477885
function( index ) {
			var cloneChildren = this.children.splice( index, this.children.length - index ),
				clone = this.clone();

			for ( var i = 0; i < cloneChildren.length; ++i )
				cloneChildren[ i ].parent = clone;

			clone.children = cloneChildren;

			if ( cloneChildren[ 0 ] )
				cloneChildren[ 0 ].previous = null;

			if ( index > 0 )
				this.children[ index - 1 ].next = null;

			this.parent.add( clone, this.getIndex() + 1 );

			return clone;
		}
192500
public void removeVertex(int i) {
        this.x.remove(i);
        this.y.remove(i);
        this.z.remove(i);
        this.colors.remove(i);
        calcG();
    }
244792
public void moveChild(int from, int to) {
        if (from != to) {
            ElementBase child = children.get(from);
            ElementBase ref = children.get(to);
            children.remove(from);
            to = children.indexOf(ref);
            children.add(to, child);
            afterMoveChild(child, ref);
        }
    }
519699
function(index) {
    if(lang.isNumber(index)&& this._elColgroup) {
        var nextSibling = this._elColgroup.childNodes[index] || null;
        this._elColgroup.insertBefore(document.createElement("col"), nextSibling);
    }
}
664698
private void moveAtFirst(int n_from) {
		int eT = elements[0];
		int eF = elements[n_from];
		positions[eT] = -1;
		positions[eF] = 0;
		elements[0] = eF;
		elements[n_from] = -1;
	}
447221
private void upHeap(int idx) {
        Reference<E> e = entries.array[idx];

        int iter = idx;
        while (hasParent(iter)) {
            int pidx = parent(iter);
            Reference<E> p = entries.array[pidx];
            if (compare(e, p) < 0) {
                entries.array[pidx] = e;
                entries.array[iter] = p;
                p.index = iter;
                iter = parent(iter);
            } else {
                break;
            }
        }
        e.index = iter;
    }
186453
private void moveIndex() {
		int i = rightmostIndexBelowMax();
		if (i >= 0) {
			index[i] = index[i]+1; 
			for (int j = i+1; j<r; j++)
				index[j] = index[j-1] + 1;
		}
		else hasNext = false;
	}
196945
public void moveScriptElementsToBody ()
  {
    // Move all JS from head to body
    final ICommonsList <IHCNode> aJSNodes = new CommonsArrayList <> ();
    m_aHead.getAllAndRemoveAllJSNodes (aJSNodes);

    // Find index of first script in body
    int nFirstScriptIndex = 0;
    if (m_aBody.hasChildren ())
      for (final IHCNode aChild : m_aBody.getAllChildren ())
      {
        if (aChild instanceof IHCScript <?>)
        {
          // Check if this is a special inline script to be emitted before files
          final boolean bIsInlineBeforeFiles = (aChild instanceof IHCScriptInline <?>) &&
                                               !((IHCScriptInline <?>) aChild).isEmitAfterFiles ();
          if (!bIsInlineBeforeFiles)
          {
            // Remember index to insert before
            break;
          }
        }
        nFirstScriptIndex++;
      }

    m_aBody.addChildrenAt (nFirstScriptIndex, aJSNodes);
  }
441594
function (i) {
        var oldVal = this.array[i];
        this.array.splice(i, 1);
        this.set('length', this.array.length);
        events.trigger(this, 'remove_at', i, oldVal);

        return oldVal;
    }
769763
function ( child, index ) {
            var el = this.element();
            if ( typeof index === 'number' ) {
                var children = el.children,
                    childNum = children.length;
    
                if ( childNum > 0 && index < childNum ) {
                    el.insertBefore( child, children[index] );
                    return;
                }
            }
            el.appendChild( child );
        }
570757
private void reverseAfter(int i) {
		int start = i+1;
		int end = n-1;
		while (start < end) {
			swap(index,start,end);
			start++;
			end--;
		}
	}
1111804
def current_changed(self, i):
        
        m = self.model()
        ri = self.rootModelIndex()
        index = m.index(i, 0, ri)
        self.new_root.emit(index)
318244
public void set(int i, int value)
  {
    if (_size <= i)
      throw new IndexOutOfBoundsException(i + " >= " + _size);

    _data[i] = value;
  }
1140368
private void internalRemove(int index)
    {
        int moving = size - index - 1;
        if (moving > 0)
            System.arraycopy(cells, index + 1, cells, index, moving);
        cells[--size] = null;
    }
697670
private void inc(ArrayList<Integer> array, int index) {
        array.set(index, array.get(index) + 1);
    }
1237361
function moveNestedTags(i) {
  var this$1 = this;

  each(Object.keys(this.tags), function (tagName) {
    moveChildTag.apply(this$1.tags[tagName], [tagName, i]);
  });
}