You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ni...@apache.org on 2008/09/14 05:34:43 UTC
svn commit: r695107 - in /activemq/camel/trunk/components/camel-rest/src:
main/java/org/apache/camel/rest/model/
main/java/org/apache/camel/rest/resources/
main/java/org/apache/camel/rest/util/ test/java/org/apache/camel/rest/
test/java/org/apache/came...
Author: ningjiang
Date: Sat Sep 13 20:34:43 2008
New Revision: 695107
URL: http://svn.apache.org/viewvc?rev=695107&view=rev
Log:
Fixed the CS errors of camel-rest
Modified:
activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/EndpointLink.java
activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/Endpoints.java
activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/CamelContextResource.java
activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/EndpointResource.java
activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/util/JAXBContextResolver.java
activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/Main.java
activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/CamelContextResourceTest.java
activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/EndpointsTest.java
activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/RoutesTest.java
activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/TestSupport.java
activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/spring/CamelRouteTest.java
Modified: activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/EndpointLink.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/EndpointLink.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/EndpointLink.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/EndpointLink.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,13 +16,13 @@
*/
package org.apache.camel.rest.model;
-import org.apache.camel.Endpoint;
-
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlRootElement;
+import org.apache.camel.Endpoint;
+
/**
* @version $Revision: 1.1 $
*/
Modified: activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/Endpoints.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/Endpoints.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/Endpoints.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/model/Endpoints.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,16 +16,17 @@
*/
package org.apache.camel.rest.model;
-import org.apache.camel.CamelContext;
-import org.apache.camel.Endpoint;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
+
+import org.apache.camel.CamelContext;
+import org.apache.camel.Endpoint;
/**
* @version $Revision: 1.1 $
Modified: activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/CamelContextResource.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/CamelContextResource.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/CamelContextResource.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/CamelContextResource.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,20 +16,23 @@
*/
package org.apache.camel.rest.resources;
+
+import java.util.List;
+
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.PathParam;
+import javax.ws.rs.Produces;
+
import com.sun.jersey.spi.inject.Inject;
import com.sun.jersey.spi.resource.Singleton;
+
import org.apache.camel.CamelContext;
import org.apache.camel.Endpoint;
import org.apache.camel.model.RouteType;
import org.apache.camel.model.RoutesType;
import org.apache.camel.rest.model.Endpoints;
-import javax.ws.rs.GET;
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
-import java.util.List;
-
/**
* The resource for the CamelContext
*
Modified: activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/EndpointResource.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/EndpointResource.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/EndpointResource.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/resources/EndpointResource.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,14 +16,8 @@
*/
package org.apache.camel.rest.resources;
-import org.apache.camel.rest.model.Endpoints;
-import org.apache.camel.rest.model.EndpointLink;
-import org.apache.camel.CamelContext;
import org.apache.camel.Endpoint;
-
-import javax.ws.rs.GET;
-import javax.ws.rs.Produces;
-import javax.ws.rs.Path;
+import org.apache.camel.rest.model.EndpointLink;
/**
* @version $Revision: 1.1 $
Modified: activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/util/JAXBContextResolver.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/util/JAXBContextResolver.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/util/JAXBContextResolver.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/main/java/org/apache/camel/rest/util/JAXBContextResolver.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,18 +16,22 @@
*/
package org.apache.camel.rest.util;
+
+
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.ws.rs.ext.ContextResolver;
+import javax.ws.rs.ext.Provider;
+import javax.xml.bind.JAXBContext;
+
import com.sun.jersey.api.json.JSONJAXBContext;
+
import org.apache.camel.model.RouteType;
import org.apache.camel.model.RoutesType;
import org.apache.camel.rest.model.EndpointLink;
import org.apache.camel.rest.model.Endpoints;
-import javax.ws.rs.ext.ContextResolver;
-import javax.ws.rs.ext.Provider;
-import javax.xml.bind.JAXBContext;
-import java.util.HashMap;
-import java.util.Map;
-
/**
* @version $Revision: 1.1 $
*/
@@ -48,7 +51,7 @@
protected Class[] getJaxbClasses() {
return new Class[]{RoutesType.class, RouteType.class,
- Endpoints.class, EndpointLink.class};
+ Endpoints.class, EndpointLink.class};
}
public JAXBContext getContext(Class<?> objectType) {
Modified: activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/Main.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/Main.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/Main.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/Main.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -61,12 +60,8 @@
context.setResourceBase(WEBAPP_DIR);
context.setContextPath(WEBAPP_CTX);
context.setServer(server);
- server.setHandlers(new Handler[]{
- context
- });
- server.setConnectors(new Connector[]{
- connector
- });
+ server.setHandlers(new Handler[] {context});
+ server.setConnectors(new Connector[] {connector});
server.start();
System.out.println();
Modified: activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/CamelContextResourceTest.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/CamelContextResourceTest.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/CamelContextResourceTest.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/CamelContextResourceTest.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,17 +16,19 @@
*/
package org.apache.camel.rest.resources;
+import java.util.List;
+import junit.framework.TestCase;
+
import com.sun.jersey.api.client.Client;
import com.sun.jersey.api.client.WebResource;
import com.sun.jersey.api.client.config.ClientConfig;
import com.sun.jersey.api.client.config.DefaultClientConfig;
-import junit.framework.TestCase;
+
+
import org.apache.camel.rest.Main;
import org.apache.camel.rest.model.EndpointLink;
import org.apache.camel.rest.model.Endpoints;
-import java.util.List;
-
/**
* @version $Revision: 1.1 $
*/
Modified: activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/EndpointsTest.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/EndpointsTest.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/EndpointsTest.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/EndpointsTest.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,17 +16,11 @@
*/
package org.apache.camel.rest.resources;
-import com.sun.jersey.api.client.Client;
-import com.sun.jersey.api.client.WebResource;
-import com.sun.jersey.api.client.config.ClientConfig;
-import com.sun.jersey.api.client.config.DefaultClientConfig;
-import junit.framework.TestCase;
-import org.apache.camel.rest.Main;
+import java.util.List;
+
import org.apache.camel.rest.model.EndpointLink;
import org.apache.camel.rest.model.Endpoints;
-import java.util.List;
-
/**
* @version $Revision: 1.1 $
*/
Modified: activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/RoutesTest.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/RoutesTest.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/RoutesTest.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/RoutesTest.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,16 +16,6 @@
*/
package org.apache.camel.rest.resources;
-import com.sun.jersey.api.client.Client;
-import com.sun.jersey.api.client.WebResource;
-import com.sun.jersey.api.client.config.ClientConfig;
-import com.sun.jersey.api.client.config.DefaultClientConfig;
-import junit.framework.TestCase;
-import org.apache.camel.rest.Main;
-import org.apache.camel.rest.model.EndpointLink;
-import org.apache.camel.rest.model.Endpoints;
-
-import java.util.List;
/**
* @version $Revision: 1.1 $
Modified: activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/TestSupport.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/TestSupport.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/TestSupport.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/resources/TestSupport.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -18,12 +17,13 @@
package org.apache.camel.rest.resources;
import junit.framework.TestCase;
-import org.apache.camel.rest.Main;
-import com.sun.jersey.api.client.config.DefaultClientConfig;
-import com.sun.jersey.api.client.config.ClientConfig;
+
import com.sun.jersey.api.client.Client;
import com.sun.jersey.api.client.WebResource;
+import com.sun.jersey.api.client.config.ClientConfig;
+import com.sun.jersey.api.client.config.DefaultClientConfig;
+import org.apache.camel.rest.Main;
/**
* @version $Revision: 1.1 $
*/
Modified: activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/spring/CamelRouteTest.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/spring/CamelRouteTest.java?rev=695107&r1=695106&r2=695107&view=diff
==============================================================================
--- activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/spring/CamelRouteTest.java (original)
+++ activemq/camel/trunk/components/camel-rest/src/test/java/org/apache/camel/rest/spring/CamelRouteTest.java Sat Sep 13 20:34:43 2008
@@ -1,5 +1,4 @@
/**
- *
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
@@ -7,7 +6,7 @@
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -17,6 +16,11 @@
*/
package org.apache.camel.rest.spring;
+import java.io.StringWriter;
+import java.util.List;
+
+import javax.xml.bind.JAXBContext;
+
import junit.framework.TestCase;
import org.apache.camel.CamelContext;
import org.apache.camel.model.RouteType;
@@ -25,10 +29,6 @@
import org.springframework.context.support.AbstractXmlApplicationContext;
import org.springframework.context.support.FileSystemXmlApplicationContext;
-import javax.xml.bind.JAXBContext;
-import java.util.List;
-import java.io.StringWriter;
-
/**
* @version $Revision: 1.1 $
*/