Skip to content

Commit

Permalink
Merge pull request #48 from andyYuanFZM/master
Browse files Browse the repository at this point in the history
release1.0.10
  • Loading branch information
andyYuanFZM authored Dec 22, 2020
2 parents 69569ff + 938920f commit 8f3b0dd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 30 deletions.
34 changes: 6 additions & 28 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,43 +2,21 @@
调用chain33 rpc接口的java客户端。

# 使用
1.添加依赖
``` java
<dependency>
<groupId>cn.chain33</groupId>
<artifactId>sdk-java</artifactId>
<version>1.0.8</version>
</dependency>
```
如果直接使用jar包,需要自己导入依赖的包
1.下载chain33-sdk-java 1.0.10版本
下载地址:https://github.com/33cn/chain33-sdk-java/releases/download/1.0.10/chain33-sdk-java-1.0.10.jar.zip
解压后,通过mvn下载依赖jar包
这边也提供jar包下载:https://bty33.oss-cn-shanghai.aliyuncs.com/java-sdk-jar.zip

``` xml
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>3.5.1</version>
</dependency>

<dependency>
<groupId>com.alibaba</groupId>
<artifactId>fastjson</artifactId>
<version>1.2.47</version>
</dependency>

<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.5.3</version>
</dependency>
```
2.使用RpcClient调用接口
2.整备好环境,使用RpcClient调用接口

``` java
初始化,设置Ip端口
RpcClient client = new RpcClient("x.x.x.x",8801);
调用接口
client.接口();
```

# 接口列表
下面罗列的是java sdk提供的接口,具体调用可以参考测试代码里的例子

Expand Down
3 changes: 1 addition & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,12 @@

<groupId>cn.chain33</groupId>
<artifactId>chain33-sdk-java</artifactId>
<version>1.0.8</version>
<version>1.0.10</version>
<packaging>jar</packaging>

<name>chain33-sdk-java</name>

<dependencies>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
Expand Down

0 comments on commit 8f3b0dd

Please sign in to comment.