Internal API refactoring #359

Merged
jwharm merged 4 commits from api-refactorings into main 2026-05-06 22:14:46 +02:00
Owner

Renamed several methods in Java-GI utility classes:

Interop:

  • Removed the Arena parameters from get...ArrayFrom() methods that do not need to use an arena.
  • Renamed getStringFrom() and get...ArrayFrom() to getString() and get...Array()
  • Renamed allocateNativeString() and allocateNativeArray() to allocate()

InstanceCache:

  • Renamed getForType() to get() and getForTypeClass() to getTypeClass()

The methods currently still exist with the old names and signatures, with a @Deprecated annotation. These methods will be removed in the next release.

Renamed several methods in Java-GI utility classes: Interop: * Removed the `Arena` parameters from `get...ArrayFrom()` methods that do not need to use an arena. * Renamed `getStringFrom()` and `get...ArrayFrom()` to `getString()` and `get...Array()` * Renamed `allocateNativeString()` and `allocateNativeArray()` to `allocate()` InstanceCache: * Renamed `getForType()` to `get()` and `getForTypeClass()` to `getTypeClass()` The methods currently still exist with the old names and signatures, with a `@Deprecated` annotation. These methods will be removed in the next release.
Remove arena parameters from get...ArrayFrom() methods: update code generator, utility classes and tests
All checks were successful
Run Gradle build / publish (push) Successful in 2m12s
a960cc06e4
* Change getFooFrom() to getFoo()
* Change allocateNativeArray() to allocate()

Shorter names are easier to use and remember, and require less code and Javadoc to be generated.
* Change getForType() to get()
* Change getForTypeClass() to getTypeClass()

Shorter names are easier to use and remember, and require less code and Javadoc to be generated.
jwharm merged commit c8e658f2c7 into main 2026-05-06 22:14:46 +02:00
jwharm deleted branch api-refactorings 2026-05-06 22:14:51 +02:00
Sign in to join this conversation.
No description provided.