carldea / java-panama-workshop

This is a one day workshop to help people get started with Java's Project Panama foreign function and memory access APIs as an alternative solution to JNI.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

java-panama-workshop

Welcome to this one day workshop on Java's Project Panama! The goal of the workshop is to help you be proficient with Java's new foreign function and memory access APIs. These APIs are an alternative solution to JNI (Java Native Interface).

Before beginning the workshop and labs be sure to follow the instructions to install the required libraries located in installs.

The following are the labs. Answers for lab exercises are in a file called answers.md in each lab directory.

  1. Lab 1 - Panama Hello World
  2. Lab 2 - Primitives & Arrays
  3. Lab 3 - Memory Layouts & C Pointers
  4. Lab 4 - Callbacks
  5. Lab 5 - Third Party Libraries

The Jfokus 2022 Hands-on-lab of Project Panama 4 Newbies can be found here: https://www.slideshare.net/CarlDea/panama4newbiesjfokus2slidespdf The following are addition tutorials the workshop was derived from:

  1. Part 1 Introduction - https://foojay.io/today/project-panama-for-newbies-part-1/
  2. Part 2 Pointers/Structs - https://foojay.io/today/project-panama-for-newbies-part-2/
  3. Part 3 Calling 3rd party libraries - https://foojay.io/today/project-panama-for-newbies-part-3/
  4. Part 4 Callbacks - https://foojay.io/today/project-panama-for-newbies-part-4/

The following is a new series of articles on Panama Polyglot where Java code can talk to other native languages.

  1. Part 1 C++ - https://foojay.io/today/java-panama-polyglot-part1
  2. Part 2 Swift - https://foojay.io/today/java-panama-polyglot-swift-part-2
  3. Part 3 Python - https://foojay.io/today/java-panama-polyglot-part-3

Any feedback is always welcome.

This is an image

About

This is a one day workshop to help people get started with Java's Project Panama foreign function and memory access APIs as an alternative solution to JNI.


Languages

Language:Java 61.0%Language:Shell 20.0%Language:C 10.7%Language:Batchfile 8.3%