public Object getProperty(Object obj) {
        if (getMethod != null) {
            try {
                return getMethod.invoke(obj);
            } catch (Exception e) {
                throw new FieldAccessException(e);
            }
        }
        if (field != null) {
            try {
                return field.get(obj);
            } catch (IllegalAccessException e) {
                throw new FieldAccessException(e);
            }
        }
        throw new FieldAccessException(String.format("Can't find accessor of get property value of %s", name));
    }