Here you can find the source of swap(Object[] x, int a, int b)
private static void swap(Object[] x, int a, int b)
//package com.java2s; /*// w w w. j a va 2s. c o m Leola Programming Language Author: Tony Sparks See license.txt */ public class Main { /** * Swaps x[a] with x[b]. */ private static void swap(Object[] x, int a, int b) { Object t = x[a]; x[a] = x[b]; x[b] = t; } }