Skip to content

Navigation Menu

Sign in
Appearance settings
Sign up
Appearance settings
Open more actions menu

Latest commit

 

History

12 Commits
12 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

apijson-jackson

腾讯 APIJSON 8.0.2+ 的 jackson 插件,简化使用。
A jackson plugin for Tencent APIJSON 8.0.2+.

添加依赖

Add Dependency

Maven

1. 在 pom.xml 中添加 JitPack 仓库

1. Add the JitPack repository to pom.xml

	<repositories>
		<repository>
		    <id>jitpack.io</id>
		    <url>https://jitpack.io</url>
		</repository>
	</repositories>

image


2. 在 pom.xml 中添加 apijson-jackson 依赖

2. Add the apijson-jackson dependency to pom.xml

	<dependency>
	    <groupId>com.github.APIJSON</groupId>
	    <artifactId>apijson-jackson</artifactId>
	    <version>LATEST</version>
	</dependency>


Gradle

1. 在项目根目录 build.gradle 中最后添加 JitPack 仓库

1. Add the JitPack repository in your root build.gradle at the end of repositories

	allprojects {
		repositories {
			maven { url 'https://jitpack.io' }
		}
	}

2. 在项目某个 module 目录(例如 app) build.gradle 中添加 apijson-jackson 依赖

2. Add the apijson-jackson dependency in one of your modules(such as app)

	dependencies {
	        implementation 'com.github.APIJSON:apijson-jackson:latest'
	}


初始化

Initialization

1.把所有 apijson.framework 中的解析类都替换成 apijson.jackson 的

1.Replace all apijson.framework classes to that of apijson.jackson what have same names

import apijson.jackson.APIJSONApplication; // apijson.framework.APIJSONApplication;

public class DemoApplication {
    public static void main(String[] args) {
        // ...
        APIJSONApplication.init();
        // ...
    }
}
import apijson.jackson.APIJSONController; // apijson.framework.APIJSONController;

public class DemoController extends APIJSONController<Long> { // apijson.framework.APIJSONController<Long, Map<String, Object>, List<Object>>
}
import apijson.jackson.APIJSONParser; // apijson.framework.APIJSONParser;

public class DemoParser extends APIJSONParser<Long> { // apijson.framework.APIJSONParser<Long, Map<String, Object>, List<Object>>
}
import apijson.jackson.APIJSONObjectParser; // apijson.framework.APIJSONObjectParser;

public class DemoParser extends APIJSONObjectParser<Long> { // apijson.framework.APIJSONObjectParser<Long, Map<String, Object>, List<Object>>
}
import apijson.jackson.APIJSONFunctionParser; // apijson.framework.APIJSONFunctionParser;

public class DemoParser extends APIJSONFunctionParser<Long> { // apijson.framework.APIJSONFunctionParser<Long, Map<String, Object>, List<Object>>
}
import apijson.jackson.APIJSONVerifier; // apijson.framework.APIJSONVerifier;

public class DemoParser extends APIJSONVerifier<Long> { // apijson.framework.APIJSONVerifier<Long, Map<String, Object>, List<Object>>
}
import apijson.jackson.APIJSONSQLConfig; // apijson.framework.APIJSONSQLConfig;

public class DemoSQLConfig extends APIJSONSQLConfig<Long> { // apijson.framework.APIJSONSQLConfig<Long, Map<String, Object>, List<Object>>
}
import apijson.jackson.APIJSONSQLExecutor; // apijson.framework.APIJSONSQLExecutor;

public class DemoSQLExecutor extends APIJSONSQLExecutor<Long> { // apijson.framework.APIJSONSQLExecutor<Long, Map<String, Object>, List<Object>>
}

...


参考 APIJSONController 的注释及 APIJSONBootDemoControllerDemoApplication

See document in APIJSONController and DemoController, DemoApplication in APIJSONBoot



有问题可以去 Tencent/APIJSON 提 issue
Tencent/APIJSON#36



点右上角 ⭐Star 支持一下,谢谢 ^_^

Please ⭐Star this project ^_^

https://github.com/APIJSON/apijson-jackson

About

腾讯 APIJSON 的 jackson 插件,简化使用。A jackson plugin for Tencent APIJSON.

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.