@Path("resource_path"):
The @Path annotation defines the path to the base URL or resource_path. The base URL is based on the application's name, the servlet, and the URL pattern from the web.xml configuration file.

@PathParam:
The @PathParam annotation is used to inject values from the URL into a method parameter. In this way, one can inject, say, the ID of a resource into the method for getting the correct object.

@GET:
The @GET annotation indicates that the method will answer to an HTTP GET request.

@PUT:
The @PUT annotation indicates that the method will answer to an HTTP PUT request.

@POST:
The @POST annotation indicates that the method will answer to an HTTP POST request.

@DELETE:
The @DELETE annotation indicates that the method will answer to an HTTP DELETE request.

@Produces(MediaType.TEXT_PLAIN):
The @Produces annotation defines which MIME type is delivered by a method annotated with any HTTP annotated methods. In the given example, a text (text/plain) is produced. Other examples would be application/xml or application/json.

@Consumes(type):
The @Consumes annotation defines which MIME type is consumed by this method.

JAX-RS annotations的更多相关文章

  1. 使用 Zipkin 和 Brave 实现分布式系统追踪(基础篇)

    一.Zipkin 1.1.简介 Zipkin 是一款开源的分布式实时数据追踪系统(Distributed Tracking System),基于 Google Dapper 的论文设计而来,由 Twi ...

  2. Eclipse 双击变量,其他相同变量有底色

    转载:http://blog.csdn.net/majian_1987/article/details/46691697 方便下次查找. 在Eclipse中,鼠标选中或者光标移动到Java类的变量名时 ...

  3. JAX-RS

    一.简介 JAX-RS(Java API for RESTful Web Services),是JAVAEE6中提出的Java 编程语言的应用程序接口,支持按照表述性状态转移(REST)架构风格创建W ...

  4. Java Web Services (0) - Overview

    前言第1章 Web服务快速入门 1.1 Web服务杂项 1.2 Web服务有什么好处 1.3 Web服务和面向服务的架构 1.4 Web服务简史 1.4.1 从DCE/RPC到XML-RPC 1.4. ...

  5. 调用链系列二、Zipkin 和 Brave 实现(springmvc、RestTemplate)服务调用跟踪

    Brave介绍 1.Brave简介 Brave 是用来装备 Java 程序的类库,提供了面向标准Servlet.Spring MVC.Http Client.JAX RS.Jersey.Resteas ...

  6. Zipkin和Brave实现http服务调用的跟踪

    使用Zipkin和Brave实现http服务调用的跟踪,Brave 是用来装备Java程序的类库,提供了面向标准Servlet.Spring MVC.Http Client.JAX RS.Jersey ...

  7. 原理分析dubbo分布式应用中使用zipkin做链路追踪

    zipkin是什么 Zipkin是一款开源的分布式实时数据追踪系统(Distributed Tracking System),基于 Google Dapper的论文设计而来,由 Twitter 公司开 ...

  8. java各种框架的比较,分析

    Spring 框架 优点 1.提供了一种管理对象的方法,可以把中间层的对象有效地组织起来 2.采用了分层结构,可以增量引入到项目中. 3.代码测试较容易 4.非侵入性,应用程序对Spring API的 ...

  9. apache基金会开源项目简介

    apache基金会开源项目简介   项目名称 描述 HTTP Server 互联网上首屈一指的HTTP服务器 Abdera Apache  Abdera项目的目标是建立一个功能完备,高效能的IETF ...

  10. 怎样在 Azure 应用服务中生成和部署 Java API 应用

    先决条件 Java 开发人员工具包 8(或更高版本) 已在开发计算机上安装 Maven 已在开发计算机上安装 Git Azure 订阅付费版或试用版 HTTP 测试应用程序,如 Postman 使用 ...

随机推荐

  1. C++中public、protected、private的差别

    第一: private,public,protected的訪问范围:   private: 仅仅能由该类中的函数.其友元函数訪问,不能被不论什么其它訪问.该类的对象也不能訪问. protected: ...

  2. iOS运用keychain 把identifierForVendor当成唯一标识。替换advertisingIdentifier

    iOS运用keychain 结合[[[UIDevice currentDevice] identifierForVendor] UUIDString] 取得设备唯一标识 NSString *ident ...

  3. asp.net 定时执行任务代码 定时采集数据

    using System; using System.Data; using System.Configuration; using System.Collections; using System. ...

  4. 请指出document load和document ready的区别?

    共同点:这两种事件都代表的是页面文档加载时触发. 异同点: ready 事件的触发,表示文档结构已经加载完成(不包含图片等非文字媒体文件). onload 事件的触发,表示页面包含图片等文件在内的所有 ...

  5. java 中文及特殊字符校验

      java 中文及特殊字符校验 CreateTime--2017年8月25日16:54:50 Author:Marydon 一.参考链接 http://blog.csdn.net/imduan/ar ...

  6. java第三节 面向对象(上)

    //第三讲 //面向对象(上) /* 理解面向对象的概念 面向过程 在一个结构体中定义窗体的大小,位置,颜色,背景等属性,对窗口操作的函数窗口本身的定义没有任何关系 如HideWindow, Move ...

  7. JBoss和tomcat的区别

    JBoss和tomcat的区别 注意JBoss和tomcat是不一样,JBoss是一个可伸缩的服务器平台,当你的EJB程序编制完成后,如果访问量增加,只要通过增加服务器硬件就可以实现多台服务器同时运算 ...

  8. centos6.5关闭ipv6

    万境归空,道法自然 1.在/etc/modprobe.d/目录下增加一个新的配置文件ipv6.conf cat << EOF > /etc/modprobe.d/ipv6.confa ...

  9. Ubuntu16.04下的英文词典Artha

    地址: http://artha.sourceforge.net  http://artha.sourceforge.net/wiki/index.php/Download 在Ubuntu下可以直接安 ...

  10. iOS UIButton 图片文字左右互移 位置对调 解决方案

    实现类似效果: 代码实现: btnGrade.titleEdgeInsets = UIEdgeInsetsMake(, -(btnGrade.imageView?.bounds.width)!, , ...