package com.bytedance.realx.base;

import com.bytedance.covode.number.Covode;
import java.io.UnsupportedEncodingException;
import java.util.Map;

public class JniHelper {
    static {
        Covode.recordClassIndex(36949);
    }

    public static Object getStringClass() {
        return String.class;
    }

    public static Object getKey(Map.Entry entry) {
        return entry.getKey();
    }

    public static Object getValue(Map.Entry entry) {
        return entry.getValue();
    }

    public static byte[] getStringBytes(String str) {
        try {
            return str.getBytes("utf-8");
        } catch (UnsupportedEncodingException unused) {
            throw new RuntimeException("utf-8 is unsupported");
        }
    }
}
