我目前正在尝试编写一个类,为对象的所有属性定义一个泛型getter和setter。我现在拥有的最接近的东西是类的名为get和set的函数,它接受一个属性名,如果它存在的话返回它。我尝试使用计算属性名称选项来动态定义getter,但是在提供getter参数或prop未定义的错误时会出现错误。for every possible property if(prop in this){ } else{
return
org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.reflection.ReflectionException: There is no getterfor propertynamed 'colId' in 'class java.lang.Long'
Caused by: org.apache.ibatis.reflection.ReflectionException: There is
org.apache.ibatis.reflection.ReflectionException: There is no getter for propertynamed 'list' in 'class#{dataIds} and aData_type = #{dataType};
已在该类中声明了DataParameter类getter
org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.reflection.ReflectionException: There is no getterfor propertynamed 'testStr' in 'class Test.TestModel'.123123");}
在Test
Try correcting the name to the name of an existing getter, or defining a getter or field named 'PinnedTry correcting the name to the name of an existing getter, or defining a getter or field named 'PinnedTry correcting the name to the n