提交 bc6b2565 编写于 作者: L lana

Merge

/* /*
* Copyright (c) 2008, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
* *
* This code is free software; you can redistribute it and/or modify it * This code is free software; you can redistribute it and/or modify it
...@@ -28,6 +28,8 @@ import com.sun.beans.finder.MethodFinder; ...@@ -28,6 +28,8 @@ import com.sun.beans.finder.MethodFinder;
import java.lang.reflect.Method; import java.lang.reflect.Method;
import sun.reflect.misc.MethodUtil;
/** /**
* This class is intended to handle <method> element. * This class is intended to handle <method> element.
* It describes invocation of the method. * It describes invocation of the method.
...@@ -101,7 +103,7 @@ final class MethodElementHandler extends NewElementHandler { ...@@ -101,7 +103,7 @@ final class MethodElementHandler extends NewElementHandler {
if (method.isVarArgs()) { if (method.isVarArgs()) {
args = getArguments(args, method.getParameterTypes()); args = getArguments(args, method.getParameterTypes());
} }
Object value = method.invoke(bean, args); Object value = MethodUtil.invoke(method, bean, args);
return method.getReturnType().equals(void.class) return method.getReturnType().equals(void.class)
? ValueObjectImpl.VOID ? ValueObjectImpl.VOID
: ValueObjectImpl.create(value); : ValueObjectImpl.create(value);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册