Return-Path: X-Original-To: apmail-cxf-commits-archive@www.apache.org Delivered-To: apmail-cxf-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E8A207A8F for ; Wed, 28 Sep 2011 13:04:07 +0000 (UTC) Received: (qmail 47371 invoked by uid 500); 28 Sep 2011 13:04:07 -0000 Delivered-To: apmail-cxf-commits-archive@cxf.apache.org Received: (qmail 47310 invoked by uid 500); 28 Sep 2011 13:04:07 -0000 Mailing-List: contact commits-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list commits@cxf.apache.org Received: (qmail 47263 invoked by uid 99); 28 Sep 2011 13:04:07 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 28 Sep 2011 13:04:07 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 28 Sep 2011 13:04:04 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 9FB1323888FE for ; Wed, 28 Sep 2011 13:03:43 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1176862 - in /cxf/branches/2.3.x-fixes: ./ rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/servlet/CXFNonSpringJaxrsServlet.java Date: Wed, 28 Sep 2011 13:03:43 -0000 To: commits@cxf.apache.org From: sergeyb@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20110928130343.9FB1323888FE@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: sergeyb Date: Wed Sep 28 13:03:43 2011 New Revision: 1176862 URL: http://svn.apache.org/viewvc?rev=1176862&view=rev Log: Merged revisions 1176859 via svnmerge from https://svn.apache.org/repos/asf/cxf/branches/2.4.x-fixes ................ r1176859 | sergeyb | 2011-09-28 14:02:47 +0100 (Wed, 28 Sep 2011) | 9 lines Merged revisions 1176856 via svnmerge from https://svn.apache.org/repos/asf/cxf/trunk ........ r1176856 | sergeyb | 2011-09-28 13:59:59 +0100 (Wed, 28 Sep 2011) | 1 line [CXF-2313] Minor update to the servlet ........ ................ Modified: cxf/branches/2.3.x-fixes/ (props changed) cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/servlet/CXFNonSpringJaxrsServlet.java Propchange: cxf/branches/2.3.x-fixes/ ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo Wed Sep 28 13:03:43 2011 @@ -1,2 +1,2 @@ -/cxf/branches/2.4.x-fixes:1172584,1173057,1173766,1174040,1174408,1175846,1175943,1175953,1176842 -/cxf/trunk:1172522,1173027,1173997-1173998,1174404,1175747-1175780,1175939,1175951,1176840 +/cxf/branches/2.4.x-fixes:1172584,1173057,1173766,1174040,1174408,1175846,1175943,1175953,1176842,1176859 +/cxf/trunk:1172522,1173027,1173997-1173998,1174404,1175747-1175780,1175939,1175951,1176840,1176856 Propchange: cxf/branches/2.3.x-fixes/ ------------------------------------------------------------------------------ Binary property 'svnmerge-integrated' - no diff available. Modified: cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/servlet/CXFNonSpringJaxrsServlet.java URL: http://svn.apache.org/viewvc/cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/servlet/CXFNonSpringJaxrsServlet.java?rev=1176862&r1=1176861&r2=1176862&view=diff ============================================================================== --- cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/servlet/CXFNonSpringJaxrsServlet.java (original) +++ cxf/branches/2.3.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/servlet/CXFNonSpringJaxrsServlet.java Wed Sep 28 13:03:43 2011 @@ -244,7 +244,7 @@ public class CXFNonSpringJaxrsServlet ex private String getClassNameAndProperties(String cName, Map props) { String theName = cName.trim(); - int ind = theName.lastIndexOf("("); + int ind = theName.indexOf("("); if (ind != -1 && theName.endsWith(")")) { props.putAll(CastUtils.cast(handleMapSequence(theName.substring(ind + 1, theName.length() - 1)), String.class, String.class)); @@ -322,7 +322,12 @@ public class CXFNonSpringJaxrsServlet ex + entry.getKey().substring(1)); if (m != null) { Class type = m.getParameterTypes()[0]; - Object value = PrimitiveUtils.read(entry.getValue(), type); + Object value = entry.getValue(); + if (InjectionUtils.isPrimitive(type)) { + value = PrimitiveUtils.read(entry.getValue(), type); + } else if (List.class.isAssignableFrom(type)) { + value = Collections.singletonList(value); + } InjectionUtils.injectThroughMethod(instance, m, value); } }