From 32a38664b96b0f6db2bbf0a791b457d25165ff9b Mon Sep 17 00:00:00 2001 From: vamsic007 Date: Thu, 28 Jan 2010 06:46:51 +0000 Subject: TUSCANY-3448 SCA Property and Reference annotation processing in web application results in incorrect computed names o Removed the classname prefix when name attribute is not specified in the annotation o Rev 903972 in 1.6 branch git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@903974 13f79535-47bb-0310-9956-ffa450edef68 --- .../tuscany/sca/implementation/web/introspect/PropertyProcessor.java | 4 ---- .../tuscany/sca/implementation/web/introspect/ReferenceProcessor.java | 4 ---- 2 files changed, 8 deletions(-) (limited to 'sca-java-1.x/trunk/modules/implementation-web/src') diff --git a/sca-java-1.x/trunk/modules/implementation-web/src/main/java/org/apache/tuscany/sca/implementation/web/introspect/PropertyProcessor.java b/sca-java-1.x/trunk/modules/implementation-web/src/main/java/org/apache/tuscany/sca/implementation/web/introspect/PropertyProcessor.java index 8bee80659a..4bf53e8336 100644 --- a/sca-java-1.x/trunk/modules/implementation-web/src/main/java/org/apache/tuscany/sca/implementation/web/introspect/PropertyProcessor.java +++ b/sca-java-1.x/trunk/modules/implementation-web/src/main/java/org/apache/tuscany/sca/implementation/web/introspect/PropertyProcessor.java @@ -78,8 +78,6 @@ public class PropertyProcessor extends BaseJavaClassVisitor { if (name.startsWith("set")) { name = JavaIntrospectionHelper.toPropertyName(method.getName()); } - // When the name is not specified, prefix the computed name with the class name - name = method.getDeclaringClass().getName()+"_"+name; } Map properties = type.getPropertyMembers(); @@ -113,8 +111,6 @@ public class PropertyProcessor extends BaseJavaClassVisitor { } if ("".equals(name) || name.equals(field.getType().getName())) { name = field.getName(); - // When the name is not specified, prefix the computed name with the class name - name = field.getDeclaringClass().getName()+"_"+name; } Map properties = type.getPropertyMembers(); diff --git a/sca-java-1.x/trunk/modules/implementation-web/src/main/java/org/apache/tuscany/sca/implementation/web/introspect/ReferenceProcessor.java b/sca-java-1.x/trunk/modules/implementation-web/src/main/java/org/apache/tuscany/sca/implementation/web/introspect/ReferenceProcessor.java index d8c44fbcf2..c68693f2e4 100644 --- a/sca-java-1.x/trunk/modules/implementation-web/src/main/java/org/apache/tuscany/sca/implementation/web/introspect/ReferenceProcessor.java +++ b/sca-java-1.x/trunk/modules/implementation-web/src/main/java/org/apache/tuscany/sca/implementation/web/introspect/ReferenceProcessor.java @@ -69,8 +69,6 @@ public class ReferenceProcessor extends BaseJavaClassVisitor { String name = annotation.name(); if ("".equals(name)) { name = JavaIntrospectionHelper.toPropertyName(method.getName()); - // When the name is not specified, prefix the computed name with the class name - name = method.getDeclaringClass().getName()+"_"+name; } JavaElementImpl ref = type.getReferenceMembers().get(name); // Setter override field @@ -108,8 +106,6 @@ public class ReferenceProcessor extends BaseJavaClassVisitor { String name = annotation.name(); if ("".equals(name)) { name = field.getName(); - // When the name is not specified, prefix the computed name with the class name - name = field.getDeclaringClass().getName()+"_"+name; } JavaElementImpl ref = type.getReferenceMembers().get(name); if (ref != null && ref.getElementType() == ElementType.FIELD) { -- cgit v1.2.3