Java ASCII asciiString(String fourcc)

Here you can find the source of asciiString(String fourcc)

Description

ascii String

License

BSD License

Declaration

public static byte[] asciiString(String fourcc) 

Method Source Code

//package com.java2s;
/**//  w  w  w.  j a va2 s. co m
 * This class is part of JCodec ( www.jcodec.org ) This software is distributed
 * under FreeBSD License
 * 
 * @author The JCodec project
 * 
 */

public class Main {
    public static byte[] asciiString(String fourcc) {
        char[] ch = fourcc.toCharArray();
        byte[] result = new byte[ch.length];
        for (int i = 0; i < ch.length; i++) {
            result[i] = (byte) ch[i];
        }
        return result;
    }
}

Related

  1. asciiIdx2StrIdx(String str, int asciiIdx)
  2. asciiLength(String str)
  3. asciiPaddingR(String str, int length, String padding)
  4. asciiQuads(String word)
  5. asciiString(byte[] bytes, int from, int count)
  6. AsciiStringToString(String content)
  7. asciiToBCD(byte[] ascii, int asc_len)
  8. asciiToEbcdic(String s)
  9. ASCIIToInteger(String ascii)