Introduction

Heraj는 aergo 에 대한 java framework입니다.

Install

maven이나 gradle을 사용해서 설치할 수 있습니다.

Maven

<repositories>
  <repository>
    <id>jcenter</id>
    <url>https://jcenter.bintray.com</url>
  </repository>
</repositories>

...

<dependencies>
  <dependency>
    <groupId>io.aergo</groupId>
    <artifactId>heraj-transport</artifactId>
    <version>${herajVersion}</version>
  </dependency>
  <dependency>
    <groupId>io.aergo</groupId>
    <artifactId>heraj-wallet</artifactId>
    <version>${herajVersion}</version>
  </dependency>
  <dependency>
    <groupId>io.aergo</groupId>
    <artifactId>heraj-smart-contract</artifactId>
    <version>${herajVersion}</version>
  </dependency>
</dependencies>

Gradle

repositories {
  jcenter()
}

...

dependencies {
  implementation "io.aergo:heraj-transport:${herajVersion}"
  implementation "io.aergo:heraj-wallet:${herajVersion}"
  implementation "io.aergo:heraj-smart-contract:${herajVersion}"
}

Compatibility

Heraj는 jdk7 이상의 버전과 호환됩니다. 하지만 jdk8을 사용하는 것을 추천합니다.

heraj aergo jdk android
1.4.x 2.2.x 7 or higher 3.0 (API 11) or higher
1.3.x 2.0.x, 2.1.x 7 or higher 3.0 (API 11) or higher
1.2.2 1.3.x 7 or higher 3.0 (API 11) or higher

Annotations

4가지 종류의 annotation이 있습니다.

  • @ApiAudience.Public : Heraj 사용자용 api를 나타냅니다. 그래서 가능하면 변경되지 않습니다.
  • @ApiAudience.Private : Heraj 내부적으로 사용될 api를 나타냅니다. 언제든지 변경될 수 있기 때문에 사용하지 않는 것을 권장합니다.
  • @ApiStability.Stable : Major버전에서만 변경될 수 있는 안정적인 api입니다.
  • @ApiStability.Unstable : 가능하면 바꾸지 않지만 하위 호환이 되지 않을 수도 있는 api입니다.

Heraj를 사용할 때 클래스에 적혀 있는 annotation들의 의미를 잘 생각해주세요.