2020-10-13 11:43:16 +02:00
TDLight Java
2020-08-20 12:18:04 +02:00
====================
2020-08-20 12:22:02 +02:00
2021-05-26 00:05:49 +02:00
[![Build Status ](https://img.shields.io/github/workflow/status/tdlight-team/tdlight-java/Maven%20Package?style=flat-square )](https://travis-ci.com/tdlight-team/tdlight-java-natives)
[![Release tag ](https://img.shields.io/github/v/release/tdlight-team/tdlight-java.svg?include_prereleases&style=flat-square )](https://github.com/tdlight-team/tdlight-java/releases)
[![Java profiler ](https://local.cavallium.it/mirrors/jprofiler-logo/jprofiler-logo-badge.svg )](https://www.ej-technologies.com/products/jprofiler/overview.html)
2020-10-13 11:43:16 +02:00
2021-09-27 19:27:13 +02:00
Complete Bot and Userbot Telegram library written in Java based on TDLib
2020-08-20 12:22:02 +02:00
2021-09-27 19:27:13 +02:00
## Supported platforms
Java versions: from Java 8 to Java 17
2020-08-20 12:18:04 +02:00
2021-09-27 19:27:13 +02:00
Operating systems: Linux, Windows, MacOS
2020-08-20 12:18:04 +02:00
2021-09-27 19:27:13 +02:00
CPU architectures:
- i386/x86 (Linux, Windows)
- amd64/x86_64 (Linux, Windows, OSX)
- armhf/armv7 (Linux)
- aarch64/armv8/arm64 (Linux)
- s390x (Linux)
- ppc64el/ppc64le (Linux)
2020-08-20 12:18:04 +02:00
Required libraries for linux: OpenSSL and zlib
2021-09-30 19:14:54 +02:00
Required libraries for OSX: brew, openssl
2021-09-27 19:27:13 +02:00
## How to use the library
### Installing with Maven
2020-08-20 12:18:04 +02:00
```xml
2021-09-27 19:27:13 +02:00
< project >
< repositories >
< repository >
< id > mchv< / id >
< name > MCHV Apache Maven Packages< / name >
< url > https://mvn.mchv.eu/repository/mchv/< / url >
< / repository >
< / repositories >
< dependencies >
< dependency >
< groupId > it.tdlight< / groupId >
< artifactId > tdlight-java< / artifactId >
< version > VERSION< / version >
< / dependency >
< dependency >
< groupId > it.tdlight< / groupId >
< artifactId > tdlight-natives-linux-amd64< / artifactId >
< version > NATIVES_VERSION< / version >
< / dependency >
<!-- Include other native versions that you want, for example for windows, osx, ... -->
< / dependencies >
< / project >
2020-08-23 15:59:19 +02:00
```
2021-09-27 19:27:13 +02:00
Replace `VERSION` with the latest release version, you can find it [here ](https://github.com/tdlight-team/tdlight-java/releases ).
Replace `NATIVES_VERSION` with the latest native version.
Make sure that you are using the correct natives version for the release that you are using.
### Installing with Gradle
2020-08-20 12:18:04 +02:00
```groovy
repositories {
2020-12-30 00:05:47 +01:00
maven { url "https://mvn.mchv.eu/repository/mchv/" }
2020-08-20 12:18:04 +02:00
}
dependencies {
2021-09-27 19:27:13 +02:00
implementation 'it.tdlight:tdlight-java:LATEST_VERSION'
implementation 'it.tdlight:tdlight-natives-linux-amd64:NATIVES_VERSION'
// Include other native versions that you want, for example for windows, osx, ...
2020-08-20 12:18:04 +02:00
}
```
2021-09-27 19:27:13 +02:00
Replace `VERSION` with the latest release version, you can find it [here ](https://github.com/tdlight-team/tdlight-java/releases ).
Replace `NATIVES_VERSION` with the latest native version.
Make sure that you are using the correct natives version for the release that you are using.
### Native dependencies
To use TDLight Java you need to include one or more native dependencies:
2020-12-30 00:05:47 +01:00
- `tdlight-natives-linux-amd64`
- `tdlight-natives-linux-aarch64`
- `tdlight-natives-linux-x86`
- `tdlight-natives-linux-armv6`
- `tdlight-natives-linux-armv7`
- `tdlight-natives-linux-ppc64le`
- `tdlight-natives-windows-amd64`
- `tdlight-natives-osx-amd64`
2020-08-20 12:18:04 +02:00
## Usage
Simple initialization of a native TDLib client
2021-01-24 13:25:25 +01:00
2021-09-27 19:27:13 +02:00
An example on how to use TDLight Java can be found here: [Example.java ](https://github.com/tdlight-team/tdlight-java/blob/master/example/src/main/java/it.tdlight.example/Example.java )
2020-10-13 02:02:24 +02:00
2021-09-27 19:27:13 +02:00
### TDLight methods documentation
[TdApi JavaDoc ](https://tdlight-team.github.io/tdlight-docs )
2020-08-20 13:46:17 +02:00
2020-08-28 21:38:49 +02:00
### TDLight extended features
2021-09-27 19:27:13 +02:00
TDLight has some extended features compared to TDLib, that you can see on the [TDLight official repository ](https://github.com/tdlight-team/tdlight#tdlight-extra-features ).
2020-08-28 21:38:49 +02:00
2020-08-20 12:18:04 +02:00
## About
2020-08-20 22:03:59 +02:00
### License
2020-08-20 13:35:14 +02:00
TDLight is licensed by Andrea Cavalli < andrea @ cavallium . it > under the terms of the GNU Lesser General Public License 3
2020-08-20 12:18:04 +02:00
2020-08-20 13:35:14 +02:00
### Libraries licenses
2020-08-20 12:18:04 +02:00
2020-08-20 13:35:14 +02:00
JTDlib is licensed by Ernesto Castellotti < erny.castell @ gmail . com > under the terms of the GNU Lesser General Public License 3
TDLib is licensed by Aliaksei Levin < levlam @ telegram . org > and Arseny Smirnov < arseny30 @ gmail . com > under the terms of the Boost Software License
OpenSSL is licensed under the terms of Apache License v2
2020-08-20 17:10:36 +02:00
Zlib is licensed under the terms of Zlib license