static

in chill-java/src/main/java/com/twitter/chill/java/BitSetSerializer.java [45:64]


    static {
        try {
            wordsField = BitSet.class.getDeclaredField("words");
            wordsField.setAccessible(true);
        } catch (NoSuchFieldException e) {
            throw new KryoException("Error while getting field 'words' of bitSet", e);
        }
        try {
            bitSetConstructor = BitSet.class.getDeclaredConstructor(long[].class);
            bitSetConstructor.setAccessible(true);
        } catch (NoSuchMethodException e) {
            throw new KryoException("Unable to get BitSet(long[]) constructor", e);
        }
        try {
            recalculateWordsInUseMethod = BitSet.class.getDeclaredMethod("recalculateWordsInUse");
            recalculateWordsInUseMethod.setAccessible(true);
        } catch (NoSuchMethodException e) {
            throw new KryoException("Unable to get BitSet.recalculateWordsInUse() method", e);
        }
    }