All Downloads are FREE. Search and download functionalities are using the official Maven repository.

hydraql.shaded.fastjson2.writer.FieldWriterInt64Field Maven / Gradle / Ivy

The newest version!
package hydraql.shaded.fastjson2.writer;

import hydraql.shaded.fastjson2.JSONException;

import java.lang.reflect.Field;

final class FieldWriterInt64Field
        extends FieldWriterInt64 {
    FieldWriterInt64Field(String name, int ordinal, long features, String format, String label, Field field) {
        super(name, ordinal, features, format, label, Long.class, field, null);
    }

    @Override
    public Object getFieldValue(T object) {
        try {
            return field.get(object);
        } catch (IllegalArgumentException | IllegalAccessException e) {
            throw new JSONException("field.get error, " + fieldName, e);
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy