Here you can find the source of toPrimitive(Character value)
public static char toPrimitive(Character value)
//package com.java2s; //License from project: Apache License public class Main { public static byte toPrimitive(Byte value) { return null == value ? 0 : value.byteValue(); }/* w w w.ja va 2 s .c o m*/ public static short toPrimitive(Short value) { return null == value ? 0 : value.shortValue(); } public static int toPrimitive(Integer value) { return null == value ? 0 : value.intValue(); } public static long toPrimitive(Long value) { return null == value ? 0 : value.longValue(); } public static double toPrimitive(Double value) { return null == value ? 0 : value.doubleValue(); } public static float toPrimitive(Float value) { return null == value ? 0 : value.floatValue(); } public static char toPrimitive(Character value) { return null == value ? 0 : value.charValue(); } public static boolean toPrimitive(Boolean value) { return null == value ? false : value.booleanValue(); } }