camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hadr...@apache.org
Subject svn commit: r836080 - in /camel/trunk: camel-core/src/main/java/org/apache/camel/impl/converter/ components/camel-spring/src/test/resources/ components/camel-web/src/main/java/org/apache/camel/web/resources/ components/camel-web/src/main/java/org/apach...
Date Sat, 14 Nov 2009 00:47:03 GMT
Author: hadrian
Date: Sat Nov 14 00:47:02 2009
New Revision: 836080

URL: http://svn.apache.org/viewvc?rev=836080&view=rev
Log:
A bit more cleanup of api and compile warnings...

Modified:
    camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/AnnotationTypeConverterLoader.java
    camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/DefaultTypeConverter.java
    camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodFallbackTypeConverter.java
    camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodTypeConverter.java
    camel/trunk/components/camel-spring/src/test/resources/log4j.properties
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/CamelContextResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentsResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersFromResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ExchangeResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguageResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguagesResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/RouteResource.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/AggregateDefinitionRenderer.java
    camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/CatchDefinitionRenderer.java

Modified: camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/AnnotationTypeConverterLoader.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/AnnotationTypeConverterLoader.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/AnnotationTypeConverterLoader.java
(original)
+++ camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/AnnotationTypeConverterLoader.java
Sat Nov 14 00:47:02 2009
@@ -36,6 +36,7 @@
 import org.apache.camel.TypeConverter;
 import org.apache.camel.spi.PackageScanClassResolver;
 import org.apache.camel.spi.TypeConverterRegistry;
+import org.apache.camel.util.CastUtils;
 import org.apache.camel.util.ObjectHelper;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
@@ -50,7 +51,7 @@
     public static final String META_INF_SERVICES = "META-INF/services/org/apache/camel/TypeConverter";
     private static final transient Log LOG = LogFactory.getLog(AnnotationTypeConverterLoader.class);
     protected PackageScanClassResolver resolver;
-    private Set<Class> visitedClasses = new HashSet<Class>();
+    private Set<Class<?>> visitedClasses = new HashSet<Class<?>>();
 
     public AnnotationTypeConverterLoader(PackageScanClassResolver resolver) {
         this.resolver = resolver;
@@ -127,14 +128,14 @@
     /**
      * Loads all of the converter methods for the given type
      */
-    protected void loadConverterMethods(TypeConverterRegistry registry, Class type) {
+    protected void loadConverterMethods(TypeConverterRegistry registry, Class<?> type)
{
         if (visitedClasses.contains(type)) {
             return;
         }
         visitedClasses.add(type);
         try {
             Method[] methods = type.getDeclaredMethods();
-            CachingInjector injector = null;
+            CachingInjector<?> injector = null;
 
             for (Method method : methods) {
                 // this may be prone to ClassLoader or packaging problems when the same class
is defined
@@ -146,7 +147,7 @@
                 }
             }
 
-            Class superclass = type.getSuperclass();
+            Class<?> superclass = type.getSuperclass();
             if (superclass != null && !superclass.equals(Object.class)) {
                 loadConverterMethods(registry, superclass);
             }
@@ -155,8 +156,7 @@
         }
     }
 
-    @SuppressWarnings("unchecked")
-    private CachingInjector handleHasConverterAnnotation(TypeConverterRegistry registry,
Class type, CachingInjector injector, Method method) {
+    private CachingInjector<?> handleHasConverterAnnotation(TypeConverterRegistry registry,
Class<?> type, CachingInjector<?> injector, Method method) {
         if (isValidConverterMethod(method)) {
             int modifiers = method.getModifiers();
             if (isAbstract(modifiers) || !isPublic(modifiers)) {
@@ -174,7 +174,7 @@
                                 new StaticMethodTypeConverter(method));
                     } else {
                         if (injector == null) {
-                            injector = new CachingInjector(registry, type);
+                            injector = new CachingInjector<Object>(registry, CastUtils.cast(type,
Object.class));
                         }
                         registerTypeConverter(registry, method, toType, fromType,
                                 new InstanceMethodTypeConverter(injector, method));
@@ -188,8 +188,7 @@
         return injector;
     }
 
-    @SuppressWarnings("unchecked")
-    private CachingInjector handleHasFallbackConverterAnnotation(TypeConverterRegistry registry,
Class type, CachingInjector injector, Method method) {
+    private CachingInjector<?> handleHasFallbackConverterAnnotation(TypeConverterRegistry
registry, Class<?> type, CachingInjector<?> injector, Method method) {
         if (isValidFallbackConverterMethod(method)) {
             int modifiers = method.getModifiers();
             if (isAbstract(modifiers) || !isPublic(modifiers)) {
@@ -205,7 +204,7 @@
                         registerFallbackTypeConverter(registry, new StaticMethodFallbackTypeConverter(method,
registry));
                     } else {
                         if (injector == null) {
-                            injector = new CachingInjector(registry, type);
+                            injector = new CachingInjector<Object>(registry, CastUtils.cast(type,
Object.class));
                         }
                         registerFallbackTypeConverter(registry, new InstanceMethodFallbackTypeConverter(injector,
method, registry));
                     }
@@ -219,7 +218,7 @@
     }
 
     protected void registerTypeConverter(TypeConverterRegistry registry,
-                                         Method method, Class toType, Class fromType, TypeConverter
typeConverter) {
+            Method method, Class<?> toType, Class<?> fromType, TypeConverter
typeConverter) {
         registry.addTypeConverter(toType, fromType, typeConverter);
     }
 

Modified: camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/DefaultTypeConverter.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/DefaultTypeConverter.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/DefaultTypeConverter.java
(original)
+++ camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/DefaultTypeConverter.java
Sat Nov 14 00:47:02 2009
@@ -81,6 +81,7 @@
         return convertTo(type, null, value);
     }
 
+    @SuppressWarnings("unchecked")
     public <T> T convertTo(Class<T> type, Exchange exchange, Object value) {
         Object answer;
         try {
@@ -112,6 +113,7 @@
         return mandatoryConvertTo(type, null, value);
     }
 
+    @SuppressWarnings("unchecked")
     public <T> T mandatoryConvertTo(Class<T> type, Exchange exchange, Object
value) throws NoTypeConversionAvailableException {
         Object answer;
         try {
@@ -203,7 +205,7 @@
         return Void.TYPE;
     }
 
-    public void addTypeConverter(Class toType, Class fromType, TypeConverter typeConverter)
{
+    public void addTypeConverter(Class<?> toType, Class<?> fromType, TypeConverter
typeConverter) {
         if (LOG.isTraceEnabled()) {
             LOG.trace("Adding type converter: " + typeConverter);
         }
@@ -230,7 +232,7 @@
         }
     }
 
-    public TypeConverter getTypeConverter(Class toType, Class fromType) {
+    public TypeConverter getTypeConverter(Class<?> toType, Class<?> fromType)
{
         TypeMapping key = new TypeMapping(toType, fromType);
         return typeMappings.get(key);
     }
@@ -243,11 +245,11 @@
         this.injector = injector;
     }
 
-    public Set<Class> getFromClassMappings() {
+    public Set<Class<?>> getFromClassMappings() {
         // make sure we have loaded the converters
         checkLoaded();
 
-        Set<Class> answer = new HashSet<Class>();
+        Set<Class<?>> answer = new HashSet<Class<?>>();
         synchronized (typeMappings) {
             for (TypeMapping mapping : typeMappings.keySet()) {
                 answer.add(mapping.getFromType());
@@ -256,8 +258,8 @@
         return answer;
     }
 
-    public Map<Class, TypeConverter> getToClassMappings(Class fromClass) {
-        Map<Class, TypeConverter> answer = new HashMap<Class, TypeConverter>();
+    public Map<Class<?>, TypeConverter> getToClassMappings(Class<?> fromClass)
{
+        Map<Class<?>, TypeConverter> answer = new HashMap<Class<?>,
TypeConverter>();
         synchronized (typeMappings) {
             for (Map.Entry<TypeMapping, TypeConverter> entry : typeMappings.entrySet())
{
                 TypeMapping mapping = entry.getKey();
@@ -276,8 +278,8 @@
         return typeMappings;
     }
 
-    protected <T> TypeConverter getOrFindTypeConverter(Class toType, Object value)
{
-        Class fromType = null;
+    protected <T> TypeConverter getOrFindTypeConverter(Class<?> toType, Object
value) {
+        Class<?> fromType = null;
         if (value != null) {
             fromType = value.getClass();
         }
@@ -295,14 +297,14 @@
         return converter;
     }
 
-    public TypeConverter lookup(Class toType, Class fromType) {
+    public TypeConverter lookup(Class<?> toType, Class<?> fromType) {
         // make sure we have loaded the converters
         checkLoaded();
 
         return doLookup(toType, fromType, false);
     }
 
-    private TypeConverter doLookup(Class toType, Class fromType, boolean isSuper) {
+    private TypeConverter doLookup(Class<?> toType, Class<?> fromType, boolean
isSuper) {
 
         if (fromType != null) {
             // lets try if there is a direct match
@@ -312,7 +314,7 @@
             }
 
             // try the interfaces
-            for (Class type : fromType.getInterfaces()) {
+            for (Class<?> type : fromType.getInterfaces()) {
                 converter = getTypeConverter(toType, type);
                 if (converter != null) {
                     return converter;
@@ -320,7 +322,7 @@
             }
 
             // try super then
-            Class fromSuperClass = fromType.getSuperclass();
+            Class<?> fromSuperClass = fromType.getSuperclass();
             if (fromSuperClass != null && !fromSuperClass.equals(Object.class)) {
                 converter = doLookup(toType, fromSuperClass, true);
                 if (converter != null) {
@@ -337,9 +339,9 @@
                 Set<Map.Entry<TypeMapping, TypeConverter>> entries = typeMappings.entrySet();
                 for (Map.Entry<TypeMapping, TypeConverter> entry : entries) {
                     TypeMapping key = entry.getKey();
-                    Class aToType = key.getToType();
+                    Class<?> aToType = key.getToType();
                     if (toType.isAssignableFrom(aToType)) {
-                        Class aFromType = key.getFromType();
+                        Class<?> aFromType = key.getFromType();
                         // skip Object based we do them last
                         if (!aFromType.equals(Object.class) && aFromType.isAssignableFrom(fromType))
{
                             return entry.getValue();
@@ -393,19 +395,19 @@
      * Represents a mapping from one type (which can be null) to another
      */
     protected static class TypeMapping {
-        Class toType;
-        Class fromType;
+        Class<?> toType;
+        Class<?> fromType;
 
-        public TypeMapping(Class toType, Class fromType) {
+        public TypeMapping(Class<?> toType, Class<?> fromType) {
             this.toType = toType;
             this.fromType = fromType;
         }
 
-        public Class getFromType() {
+        public Class<?> getFromType() {
             return fromType;
         }
 
-        public Class getToType() {
+        public Class<?> getToType() {
             return toType;
         }
 
@@ -433,7 +435,7 @@
             return "[" + fromType + "=>" + toType + "]";
         }
 
-        public boolean isApplicable(Class fromClass) {
+        public boolean isApplicable(Class<?> fromClass) {
             return fromType.isAssignableFrom(fromClass);
         }
     }

Modified: camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodFallbackTypeConverter.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodFallbackTypeConverter.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodFallbackTypeConverter.java
(original)
+++ camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodFallbackTypeConverter.java
Sat Nov 14 00:47:02 2009
@@ -31,12 +31,12 @@
  * @version $Revision$
  */
 public class InstanceMethodFallbackTypeConverter implements TypeConverter {
-    private final CachingInjector injector;
+    private final CachingInjector<?> injector;
     private final Method method;
     private final boolean useExchange;
     private final TypeConverterRegistry registry;
 
-    public InstanceMethodFallbackTypeConverter(CachingInjector injector, Method method, TypeConverterRegistry
registry) {
+    public InstanceMethodFallbackTypeConverter(CachingInjector<?> injector, Method
method, TypeConverterRegistry registry) {
         this.injector = injector;
         this.method = method;
         this.useExchange = method.getParameterTypes().length == 4;

Modified: camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodTypeConverter.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodTypeConverter.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodTypeConverter.java
(original)
+++ camel/trunk/camel-core/src/main/java/org/apache/camel/impl/converter/InstanceMethodTypeConverter.java
Sat Nov 14 00:47:02 2009
@@ -30,11 +30,11 @@
  * @version $Revision$
  */
 public class InstanceMethodTypeConverter implements TypeConverter {
-    private final CachingInjector injector;
+    private final CachingInjector<?>injector;
     private final Method method;
     private final boolean useExchange;
 
-    public InstanceMethodTypeConverter(CachingInjector injector, Method method) {
+    public InstanceMethodTypeConverter(CachingInjector<?> injector, Method method)
{
         this.injector = injector;
         this.method = method;
         this.useExchange = method.getParameterTypes().length == 2;

Modified: camel/trunk/components/camel-spring/src/test/resources/log4j.properties
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-spring/src/test/resources/log4j.properties?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-spring/src/test/resources/log4j.properties (original)
+++ camel/trunk/components/camel-spring/src/test/resources/log4j.properties Sat Nov 14 00:47:02
2009
@@ -18,7 +18,7 @@
 #
 # The logging properties used for eclipse testing, We want to see debug output on the console.
 #
-log4j.rootLogger=INFO, out
+log4j.rootLogger=WARN, out
 
 log4j.logger.org.springframework=WARN
 log4j.logger.org.apache.camel.impl.converter=WARN

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/CamelContextResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/CamelContextResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/CamelContextResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/CamelContextResource.java
Sat Nov 14 00:47:02 2009
@@ -82,8 +82,8 @@
     /**
      * Returns the system properties
      */
-    public Map getSystemProperties() {
-        return new TreeMap(System.getProperties());
+    public Map<Object, Object> getSystemProperties() {
+        return new TreeMap<Object, Object>(System.getProperties());
     }
 
     // representations

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentResource.java
Sat Nov 14 00:47:02 2009
@@ -16,14 +16,11 @@
  */
 package org.apache.camel.web.resources;
 
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
 
 /**
  * @version $Revision$
  */
 public class ComponentResource extends CamelChildResourceSupport {
-    private static final transient Log LOG = LogFactory.getLog(ComponentResource.class);
     private String id;
 
     public ComponentResource(CamelContextResource contextResource, String id) {

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentsResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentsResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentsResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ComponentsResource.java
Sat Nov 14 00:47:02 2009
@@ -19,12 +19,10 @@
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
+
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
 
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
 /**
  * Represents the list of the currently active <a href="http://camel.apache.org/component.html">components</a>
  * in the current camel context
@@ -32,8 +30,6 @@
  * @version $Revision$
  */
 public class ComponentsResource extends CamelChildResourceSupport {
-    private static final transient Log LOG = LogFactory.getLog(ComponentsResource.class);
-
     public ComponentsResource(CamelContextResource contextResource) {
         super(contextResource);
     }

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersFromResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersFromResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersFromResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersFromResource.java
Sat Nov 14 00:47:02 2009
@@ -26,9 +26,9 @@
  * @version $Revision$
  */
 public class ConvertersFromResource extends CamelChildResourceSupport {
-    private Class type;
+    private Class<?> type;
 
-    public ConvertersFromResource(CamelContextResource contextResource, Class type) {
+    public ConvertersFromResource(CamelContextResource contextResource, Class<?> type)
{
         super(contextResource);
         this.type = type;
     }
@@ -37,9 +37,9 @@
         Map<String, TypeConverter> answer = new TreeMap<String, TypeConverter>();
         DefaultTypeConverter converter = getDefaultTypeConverter();
         if (converter != null) {
-            Map<Class, TypeConverter> classes = converter.getToClassMappings(type);
-            for (Map.Entry<Class, TypeConverter> entry : classes.entrySet()) {
-                Class aClass = entry.getKey();
+            Map<Class<?>, TypeConverter> classes = converter.getToClassMappings(type);
+            for (Map.Entry<Class<?>, TypeConverter> entry : classes.entrySet())
{
+                Class<?> aClass = entry.getKey();
                 String name = ConvertersResource.nameOf(aClass);
                 answer.put(name, entry.getValue());
             }
@@ -47,8 +47,7 @@
         return answer;
     }
 
-    public Class getType() {
+    public Class<?> getType() {
         return type;
     }
-
 }

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ConvertersResource.java
Sat Nov 14 00:47:02 2009
@@ -19,29 +19,26 @@
 import java.util.Map;
 import java.util.Set;
 import java.util.TreeMap;
+
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
 
 import org.apache.camel.impl.converter.DefaultTypeConverter;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
 
 /**
  * @version $Revision$
  */
 public class ConvertersResource extends CamelChildResourceSupport {
-    private static final transient Log LOG = LogFactory.getLog(ConvertersResource.class);
-
     public ConvertersResource(CamelContextResource contextResource) {
         super(contextResource);
     }
 
-    public Map<String, Class> getFromClassTypes() {
-        Map<String, Class> answer = new TreeMap<String, Class>();
+    public Map<String, Class<?>> getFromClassTypes() {
+        Map<String, Class<?>> answer = new TreeMap<String, Class<?>>();
         DefaultTypeConverter converter = getDefaultTypeConverter();
         if (converter != null) {
-            Set<Class> classes = converter.getFromClassMappings();
-            for (Class aClass : classes) {
+            Set<Class<?>> classes = converter.getFromClassMappings();
+            for (Class<?> aClass : classes) {
                 String name = nameOf(aClass);
                 answer.put(name, aClass);
             }
@@ -61,7 +58,7 @@
 */
 
     public ConvertersFromResource getConvertersFrom(@PathParam("type") String typeName) {
-        Class type = getCamelContext().getClassResolver().resolveClass(typeName, getClass().getClassLoader());
+        Class<?> type = getCamelContext().getClassResolver().resolveClass(typeName,
getClass().getClassLoader());
         if (type == null) {
             return null;
         }
@@ -69,7 +66,7 @@
     }
 
 
-    public static String nameOf(Class aClass) {
+    public static String nameOf(Class<?> aClass) {
         return aClass.getCanonicalName();
     }
 }

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ExchangeResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ExchangeResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ExchangeResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/ExchangeResource.java
Sat Nov 14 00:47:02 2009
@@ -34,11 +34,9 @@
  */
 @ImplicitProduces(Constants.HTML_MIME_TYPES)
 public class ExchangeResource {
-    private final EndpointResource endpointResource;
     private final Exchange exchange;
 
     public ExchangeResource(EndpointResource endpointResource, Exchange exchange) {
-        this.endpointResource = endpointResource;
         this.exchange = exchange;
     }
 

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguageResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguageResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguageResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguageResource.java
Sat Nov 14 00:47:02 2009
@@ -16,14 +16,11 @@
  */
 package org.apache.camel.web.resources;
 
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
 
 /**
  * @version $Revision$
  */
 public class LanguageResource extends CamelChildResourceSupport {
-    private static final transient Log LOG = LogFactory.getLog(LanguageResource.class);
     private String id;
 
     public LanguageResource(CamelContextResource contextResource, String id) {

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguagesResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguagesResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguagesResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/LanguagesResource.java
Sat Nov 14 00:47:02 2009
@@ -19,12 +19,10 @@
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
+
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
 
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-
 /**
  * Represents the list of the currently active <a href="http://camel.apache.org/languages.html">languages</a>
  * in the current camel context
@@ -32,8 +30,6 @@
  * @version $Revision$
  */
 public class LanguagesResource extends CamelChildResourceSupport {
-    private static final transient Log LOG = LogFactory.getLog(LanguagesResource.class);
-
     public LanguagesResource(CamelContextResource contextResource) {
         super(contextResource);
     }

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/RouteResource.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/RouteResource.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/RouteResource.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/resources/RouteResource.java
Sat Nov 14 00:47:02 2009
@@ -311,7 +311,7 @@
         try {
 
             // store the route definition
-            File file = storeRoute(route, LANGUAGE_SCALA);
+            storeRoute(route, LANGUAGE_SCALA);
 
             // load the definition class
             //TODO: process the route definition using scala route builder

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/AggregateDefinitionRenderer.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/AggregateDefinitionRenderer.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/AggregateDefinitionRenderer.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/AggregateDefinitionRenderer.java
Sat Nov 14 00:47:02 2009
@@ -28,7 +28,7 @@
         // Utility class, no public or protected default constructor
     }    
 
-    public static void render(StringBuilder buffer, ProcessorDefinition processor) {
+    public static void render(StringBuilder buffer, ProcessorDefinition<?> processor)
{
         
         AggregateDefinition aggregate = (AggregateDefinition)processor;
         buffer.append(".").append(aggregate.getShortName()).append("()");

Modified: camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/CatchDefinitionRenderer.java
URL: http://svn.apache.org/viewvc/camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/CatchDefinitionRenderer.java?rev=836080&r1=836079&r2=836080&view=diff
==============================================================================
--- camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/CatchDefinitionRenderer.java
(original)
+++ camel/trunk/components/camel-web/src/main/java/org/apache/camel/web/util/CatchDefinitionRenderer.java
Sat Nov 14 00:47:02 2009
@@ -30,7 +30,7 @@
         // Utility class, no public or protected default constructor
     }
     
-    public static void render(StringBuilder buffer, ProcessorDefinition processor) {
+    public static void render(StringBuilder buffer, ProcessorDefinition<?> processor)
{
         CatchDefinition catchDef = (CatchDefinition)processor;
         buffer.append(".").append(catchDef.getShortName()).append("(");
         List<Class<Exception>> exceptions = catchDef.getExceptionClasses();



Mime
View raw message