char c = in.get();
if (Character.isHighSurrogate(c)) {
// with surrogate
char low = in.get();
int codePoint = Character.toCodePoint(c, low);
Emoji emoji = Emoji.charOf(codePoint);
out.put(getEmojiCode(emoji));
pos += 2;
} else if (c == 0x0023 || (0x0030 <= c && c <= 0x0039)) {
// 2文字で絵文字に変換される特殊文字
char c2 = in.get();
if (c2 == 0x20E3) {
out.put(getCarrierEmojiCode(Emoji.capsCharOf(c)));
} else {
out(c, out);
out(c2, out);
}
pos += 2;
} else {
Emoji emoji = Emoji.charOf(c);
if (emoji != null) {
// emoji
out.put(getEmojiCode(emoji));
} else {
// その他