cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject [2/2] cxf git commit: [CXF-6789] Adding a resource
Date Wed, 24 Feb 2016 17:19:24 GMT
[CXF-6789] Adding a resource


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/73198c5d
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/73198c5d
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/73198c5d

Branch: refs/heads/master
Commit: 73198c5da1efa83d9739b55f2d63a184504c8287
Parents: 14849cb
Author: Sergey Beryozkin <sberyozkin@gmail.com>
Authored: Wed Feb 24 17:19:10 2016 +0000
Committer: Sergey Beryozkin <sberyozkin@gmail.com>
Committed: Wed Feb 24 17:19:10 2016 +0000

----------------------------------------------------------------------
 .../java/sample/rs/service/HelloService2.java   | 42 ++++++++++++++++++++
 1 file changed, 42 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/73198c5d/distribution/src/main/release/samples/jax_rs/jaxrs_spring_boot/src/main/java/sample/rs/service/HelloService2.java
----------------------------------------------------------------------
diff --git a/distribution/src/main/release/samples/jax_rs/jaxrs_spring_boot/src/main/java/sample/rs/service/HelloService2.java
b/distribution/src/main/release/samples/jax_rs/jaxrs_spring_boot/src/main/java/sample/rs/service/HelloService2.java
new file mode 100644
index 0000000..2421047
--- /dev/null
+++ b/distribution/src/main/release/samples/jax_rs/jaxrs_spring_boot/src/main/java/sample/rs/service/HelloService2.java
@@ -0,0 +1,42 @@
+/**
+ * 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. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (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
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package sample.rs.service;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.PathParam;
+import javax.ws.rs.Produces;
+import javax.ws.rs.core.MediaType;
+
+import org.springframework.stereotype.Service;
+
+import io.swagger.annotations.Api;
+ 
+@Path("/sayHello2")
+@Service
+@Api("/sayHello2")
+public class HelloService2 {
+ 
+    @GET
+    @Path("/{a}")
+    @Produces(MediaType.TEXT_PLAIN)
+    public String sayHello(@PathParam("a") String a) {
+        return "Hello2 " + a + ", Welcome to CXF RS Spring Boot World!!!";
+    }
+    
+}


Mime
View raw message