Here you can find the source of swapLong(long value)
static public long swapLong(long value)
//package com.java2s; public class Main { /** Converts a "long" value between endian systems. */ static public long swapLong(long value) { return (((value >> 0) & 0xff) << 56) | (((value >> 8) & 0xff) << 48) | (((value >> 16) & 0xff) << 40) | (((value >> 24) & 0xff) << 32) | (((value >> 32) & 0xff) << 24) | (((value >> 40) & 0xff) << 16) | (((value >> 48) & 0xff) << 8) | (((value >> 56) & 0xff) << 0); }/*w w w . j av a 2s . c o m*/ }