Java Unsigned Number Create unsignedByteToString(int i)

Here you can find the source of unsignedByteToString(int i)

Description

unsigned Byte To String

License

Open Source License

Declaration

private static String unsignedByteToString(int i) 

Method Source Code

//package com.java2s;
/*******************************************************************************
 * Copyright (c) 2014 hangum./*from   w w  w.j  av a 2 s.  c o  m*/
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the GNU Lesser Public License v2.1
 * which accompanies this distribution, and is available at
 * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
 * 
 * Contributors:
 *     hangum - initial API and implementation
 ******************************************************************************/

public class Main {
    private static String unsignedByteToString(int i) {
        return "" + Character.forDigit(i / 16, 16) //$NON-NLS-1$
                + Character.forDigit(i % 16, 16);
    }
}

Related

  1. unsignedByteToInt(byte b)
  2. unsignedByteToInt(byte in)
  3. unsignedByteToInt(final byte b)
  4. unsignedByteToIntArray(byte[] bytes)
  5. unsignedByteToLong(final byte b)
  6. unsignedByteValue(byte[] data, int offset)
  7. unsignedByteValue(final byte input)
  8. unsignedChar(char c)
  9. unsignedChar(int val)