Java Hex Calculate toHex(int nybble)

Here you can find the source of toHex(int nybble)

Description

to Hex

License

Open Source License

Declaration

public static char toHex(int nybble) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static char toHex(int nybble) {
        if (nybble < 0 || nybble > 15) {
            throw new IllegalArgumentException();
        }// ww  w .  j a v  a 2s. c  o m
        return "0123456789ABCDEF".toLowerCase().charAt(nybble);
    }
}

Related

  1. toHex(int n, Boolean bigEndian)
  2. toHex(int n, int bytes)
  3. toHex(int n, int s)
  4. toHex(int nibble)
  5. toHex(int num)
  6. toHex(int r, int g, int b)
  7. toHex(int r, int g, int b)
  8. toHex(int r, int g, int b)
  9. toHex(int v)