Skip to main content

Packaged JDK for Python

Project description

jdk4py

A packaged JDK for Python.

PyPI version

Install

Java is made easy to install as a single Python package:

pip install jdk4py

or as a Conda package:

conda config --add channels https://conda.atoti.io
conda install jdk4py

Usage

>>> from jdk4py import JAVA, JAVA_HOME, JAVA_VERSION
>>> JAVA_HOME
PosixPath('/Users/johndoe/dev/jdk4py/jdk4py/java-runtime')
>>> JAVA
PosixPath('/Users/johndoe/dev/jdk4py/jdk4py/java-runtime/bin/java')
>>> JAVA_VERSION
(17, 0, 2)
>>> from subprocess import check_output
>>> some_java_options = ["-Xmx16G", "-Xms2G"]
>>> check_output([str(JAVA), "-jar", "HelloWorld.jar",  *some_java_options])
b"Hello, World!"

Versioning

jdk4py version contains 4 figures:

  • The first 3 figures are the Java version.
  • The fourth is jdk4py specific: it starts at 0 for each Java version and then increases.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Built Distributions

jdk4py-17.0.2.1-1-py3-none-win_amd64.whl (33.4 MB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page