Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

map to bean 的问题 #12

Open
GoogleCodeExporter opened this issue Mar 29, 2016 · 0 comments
Open

map to bean 的问题 #12

GoogleCodeExporter opened this issue Mar 29, 2016 · 0 comments

Comments

@GoogleCodeExporter
Copy link


     当bean的一些属性 在map为空的时候。 
     连续多次执行mapping代码
     mapping.mapping(map, bean);
     第一个转化没问题,
    后面的都会会报空指针异常, 必须显示指定 mappingNullValue="false"。
错误信息如下

java.lang.NullPointerException
    at com.agapple.mapping.core.process.ValueProcessInvocation.invokeSetExecutor(ValueProcessInvocation.java:71)
    at com.agapple.mapping.core.process.ValueProcessInvocation.proceed(ValueProcessInvocation.java:42)
    at com.agapple.mapping.process.DebugValueProcess.process(DebugValueProcess.java:49)
    at com.agapple.mapping.core.process.ValueProcessInvocation.proceed(ValueProcessInvocation.java:45)
    at com.agapple.mapping.process.BehaviorValueProcess.process(BehaviorValueProcess.java:43)
    at com.agapple.mapping.core.process.ValueProcessInvocation.proceed(ValueProcessInvocation.java:45)
    at com.agapple.mapping.process.BeanCreatorValueProcess.process(BeanCreatorValueProcess.java:28)
    at com.agapple.mapping.core.process.ValueProcessInvocation.proceed(ValueProcessInvocation.java:45)
    at com.agapple.mapping.process.ConvertorValueProcess.process(ConvertorValueProcess.java:89)
    at com.agapple.mapping.core.process.ValueProcessInvocation.proceed(ValueProcessInvocation.java:45)
    at com.agapple.mapping.process.DefaultValueValueProcess.process(DefaultValueValueProcess.java:40)
    at com.agapple.mapping.core.process.ValueProcessInvocation.proceed(ValueProcessInvocation.java:45)
    at com.agapple.mapping.process.ScriptValueProcess.process(ScriptValueProcess.java:50)
    at com.agapple.mapping.core.process.ValueProcessInvocation.proceed(ValueProcessInvocation.java:45)
    at com.agapple.mapping.core.BeanMappingExecutor.doFieldMapping(BeanMappingExecutor.java:243)
    at com.agapple.mapping.core.BeanMappingExecutor.execute(BeanMappingExecutor.java:65)
    at com.agapple.mapping.BeanMapping.mapping(BeanMapping.java:91)
    at com.e6soft.mapping.test.BeanMapTest.test(BeanMapTest.java:74)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
    at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
    at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
    at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
    at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
    at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:76)
    at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
    at org.junit.runners.ParentRunner$3.run(ParentRunner.java:193)
    at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:52)
    at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:191)
    at org.junit.runners.ParentRunner.access$000(ParentRunner.java:42)
    at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:184)
    at org.junit.runners.ParentRunner.run(ParentRunner.java:236)
    at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
    at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)

Original issue reported on code.google.com by [email protected] on 17 Jan 2013 at 3:29

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant