Java Long to Hex longToHex(long l)

Here you can find the source of longToHex(long l)

Description

Convert a long to a hex representation.

License

Contributor Agreement License

Parameter

Parameter Description
s A Java long.

Return

A hex representation of the long.

Declaration

public static String longToHex(long l) 

Method Source Code

//package com.java2s;
/*//from ww  w. j  av  a 2s . c  o  m
 *  Copyright (C) 2008 Pingtel Corp., certain elements licensed under a Contributor Agreement.
 *  Contributors retain copyright to elements licensed under a Contributor Agreement.
 *  Licensed to the User under the LGPL license.
 *
 */

public class Main {
    /**
     * Convert a long to a hex representation.
     * 
     * @param s
     *            A Java long.
     * @return A hex representation of the long.
     */
    public static String longToHex(long l) {

        return Long.toHexString(l);

    }
}

Related

  1. Long2HexString(long h)
  2. long2hexString(long x)
  3. long2HexString(StringBuilder buf, long value)
  4. longToHex(long a)
  5. longToHex(long l, int length)
  6. longToHex(long num)
  7. longToHex(long val, char delim)
  8. longToHexBytes(final long v)