java2pyi-1.1.0 is not a library.
Installation from crates.io
cargo install java2pyi
Building from source code and installation steps
- Clone this repo
git clone https://github.com/n08i40k/java2pyi
- Compile and install
cargo install --path .
Usage example
- Clone OpenJDK source code (required for all use-cases, otherwise, non-promitive java types won't be resolved)
git clone https://github.com/openjdk/jdk
- Remove sample file from OpenJDK source code
rm ./jdk/src/java.base/share/classes/java/lang/snippet-files/ProcessExamples.java
- Clone Telegram for Android source code
git clone https://github.com/DrKLO/Telegram
- Create directory for stub files
mkdir stubs
- Start generator
java2pyi -i ./jdk/src/java.base/share/classes/java/ -i ./Telegram/TMessagesProj/src/main/java/ -o ./stubs
Where -i is directories with .java files and -o is output directory for generated stubs.