List of usage examples for io.netty.util CharsetUtil getEncoder
@Deprecated public static CharsetEncoder getEncoder(Charset charset)
From source file:org.apache.tajo.util.StringUtils.java
License:Apache License
/** * Check Seven-bit ASCII//from w ww. ja v a2s . co m */ public static boolean isPureAscii(String v) { // get thread-safe encoder CharsetEncoder asciiEncoder = CharsetUtil.getEncoder(CharsetUtil.US_ASCII); return asciiEncoder.canEncode(v); }