Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

ismartx/summer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

summer

License Build Status

简介

基于Spring MVC的Restful框架,用于快速实现Restful Api接口。

功能

1.0

使用

maven

<mirror>
    <id>nexus</id>
    <mirrorOf>*</mirrorOf>
    <name>Private Nexus</name>
    <url>http://repo.dingdingyisheng.mobi/repository/maven-public</url>
</mirror>
<dependency>
    <groupId>org.smartx</groupId>
    <artifactId>summer-core</artifactId>
    <version>1.0</version>
</dependency>

Demo

@RestController
public class HelloController {

    @GetMapping(value = "/")
    public String summer() {
        return "Hello Summer";
    }

    @VerifyJwtRole(roles = "user,admin", verifyJwt = true)
    @GetMapping(path = "/test-annotation")
    public ResponseEntity<?> version() {
        return new ResponseEntity<>(HttpStatus.OK);
    }

    @DeleteMapping(value = "/api/1")
    public ResponseEntity<?> delete() {
        return new ResponseEntity<>(HttpStatus.OK);
    }
}

具体示例代码可以参考summer-demo项目。

Contributors

Contributors