Minecraft.Java
Discover Java runtimes, inspect requirements and select a runtime through launcher policy. Managed distribution offers describe the complete installable content accepted by the current installer.
Contract: nexa.minecraft.java/100. API index.
Typical sequence
Read the instance’s requirements before resolving selection. Use ListManagedDistributions and PrepareManagedInstall for the mapped multi-file distribution path, then commit through Install.
Behavior and limits
The older single-file distribution catalog and preparation route are not mapped in this snapshot. A selected runtime still needs platform, architecture and version compatibility.
The recorded Host maps 14 of 14 operations in this group. A mapping is subject to permission, phase, scope, platform and business preconditions. Host snapshot identifies the source revision; negotiate against the actual installed Host.
Operations
List · Discover · Inspect · ReadRequirements · ResolveSelection · SelectGlobal · SelectForInstance · ListDistributions · PrepareInstall · Install · Remove · RegisterDistributionProvider · ListManagedDistributions · PrepareManagedInstall
List
PageRequest → Page<JavaRuntime> (wrapper, item)
| Property | Contract |
|---|---|
| Local SDK method ID | 1 |
| Kind | Query |
| Permission | nexa.minecraft.java.read |
| Legal phases | Initialize, PostInitialize, Checkup, Finalize, Active |
| Idempotency | ReadOnly |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Cursor | string? | Opaque continuation or observation cursor. Reuse only in the issuing query/scope; absence and invalidity are different. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Limit | long | Requested bound on returned items. The Host may impose a smaller domain-specific limit. |
Successful result
Read Items and continue with NextCursor while preserving the original query. An absent cursor ends the sequence; an invalid cursor is an error.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. A read-only classification does not bypass budgets or guarantee a failed request can be retried indefinitely. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_List(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_List_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
Discover
| Property | Contract |
|---|---|
| Local SDK method ID | 2 |
| Kind | Operation |
| Permission | nexa.minecraft.java.write |
| Legal phases | Active |
| Idempotency | RequiredKey |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Root | RootRef | Structured RootRef value; follow its linked field contract. |
Successful result
Work has been admitted. Read or watch the owned operation through Tasks to establish its terminal result; admission is not completion.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. Supply a key for the intended effect and retain that key and inputs while resolving an uncertain reply. Do not retry with changed inputs under the same key. Re-read after revision conflicts; cancellation does not prove rollback. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_Discover(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_Discover_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
Inspect
| Property | Contract |
|---|---|
| Local SDK method ID | 3 |
| Kind | Query |
| Permission | nexa.minecraft.java.read |
| Legal phases | Initialize, PostInitialize, Checkup, Finalize, Active |
| Idempotency | ReadOnly |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Token | Guid | Opaque Host-issued handle token. Keep it with its owner and resource type. |
LoadInstanceId | Guid | Identity of the admitted load that owns this handle; it is not portable to a replacement load. |
Scope | string | Explicit target scope. The Host checks that the caller is authorized for it. |
Successful result
Decode the exact output model after Success. Preserve its identities, revision and schema metadata for subsequent domain operations.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. A read-only classification does not bypass budgets or guarantee a failed request can be retried indefinitely. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_Inspect(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_Inspect_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
ReadRequirements
EntityRequest → JavaRequirements
| Property | Contract |
|---|---|
| Local SDK method ID | 4 |
| Kind | Query |
| Permission | nexa.minecraft.java.read |
| Legal phases | Initialize, PostInitialize, Checkup, Finalize, Active |
| Idempotency | ReadOnly |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Id | EntityId | Identity in this model’s domain. Use the identity issued or declared for this object, not a display name or filesystem path. |
Successful result
Decode the exact output model after Success. Preserve its identities, revision and schema metadata for subsequent domain operations.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. A read-only classification does not bypass budgets or guarantee a failed request can be retried indefinitely. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_ReadRequirements(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_ReadRequirements_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
ResolveSelection
| Property | Contract |
|---|---|
| Local SDK method ID | 5 |
| Kind | Query |
| Permission | nexa.minecraft.java.read |
| Legal phases | Initialize, PostInitialize, Checkup, Finalize, Active |
| Idempotency | ReadOnly |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Instance | EntityId? | Identity or revision in this model’s domain; preserve ownership and exact spelling. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Runtime | EntityId? | Identity or revision in this model’s domain; preserve ownership and exact spelling. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
VersionLocal | bool | Domain value named by this field; additional accepted values and bounds are determined by the operation and Host policy. |
ExpectedRevision | Revision? | Revision observed before this change. Preserve it exactly; a mismatch requires re-reading and reconciling the target. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Successful result
Decode the exact output model after Success. Preserve its identities, revision and schema metadata for subsequent domain operations.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. A read-only classification does not bypass budgets or guarantee a failed request can be retried indefinitely. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_ResolveSelection(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_ResolveSelection_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
SelectGlobal
| Property | Contract |
|---|---|
| Local SDK method ID | 6 |
| Kind | Mutation |
| Permission | nexa.minecraft.java.write |
| Legal phases | Active |
| Idempotency | RequiredKey |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Instance | EntityId? | Identity or revision in this model’s domain; preserve ownership and exact spelling. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Runtime | EntityId? | Identity or revision in this model’s domain; preserve ownership and exact spelling. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
VersionLocal | bool | Domain value named by this field; additional accepted values and bounds are determined by the operation and Host policy. |
ExpectedRevision | Revision? | Revision observed before this change. Preserve it exactly; a mismatch requires re-reading and reconciling the target. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Successful result
Decode the exact output model after Success. Preserve its identities, revision and schema metadata for subsequent domain operations.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. Supply a key for the intended effect and retain that key and inputs while resolving an uncertain reply. Do not retry with changed inputs under the same key. Re-read after revision conflicts; cancellation does not prove rollback. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_SelectGlobal(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_SelectGlobal_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
SelectForInstance
| Property | Contract |
|---|---|
| Local SDK method ID | 7 |
| Kind | Mutation |
| Permission | nexa.minecraft.java.write |
| Legal phases | Active |
| Idempotency | RequiredKey |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Instance | EntityId? | Identity or revision in this model’s domain; preserve ownership and exact spelling. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Runtime | EntityId? | Identity or revision in this model’s domain; preserve ownership and exact spelling. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
VersionLocal | bool | Domain value named by this field; additional accepted values and bounds are determined by the operation and Host policy. |
ExpectedRevision | Revision? | Revision observed before this change. Preserve it exactly; a mismatch requires re-reading and reconciling the target. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Successful result
Decode the exact output model after Success. Preserve its identities, revision and schema metadata for subsequent domain operations.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. Supply a key for the intended effect and retain that key and inputs while resolving an uncertain reply. Do not retry with changed inputs under the same key. Re-read after revision conflicts; cancellation does not prove rollback. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_SelectForInstance(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_SelectForInstance_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
ListDistributions
PageRequest → Page<JavaDistribution> (wrapper, item)
| Property | Contract |
|---|---|
| Local SDK method ID | 8 |
| Kind | Query |
| Permission | nexa.minecraft.java.read |
| Legal phases | Initialize, PostInitialize, Checkup, Finalize, Active |
| Idempotency | ReadOnly |
| Host status | Mapped in recorded snapshot |
Aggregate published distribution providers and filter for the current OS and architecture. There may be at most eight providers and 128 entries per provider; provider replies must have no continuation cursor. The caller’s page is applied to the combined revisioned result. An empty result means no matching registered offer.
Request fields
| Field | Type | Meaning |
|---|---|---|
Cursor | string? | Opaque continuation or observation cursor. Reuse only in the issuing query/scope; absence and invalidity are different. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Limit | long | Requested bound on returned items. The Host may impose a smaller domain-specific limit. |
Successful result
Read Items and continue with NextCursor while preserving the original query. An absent cursor ends the sequence; an invalid cursor is an error.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. A read-only classification does not bypass budgets or guarantee a failed request can be retried indefinitely. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_ListDistributions(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_ListDistributions_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
PrepareInstall
JavaInstallRequest → MutationPlan
| Property | Contract |
|---|---|
| Local SDK method ID | 9 |
| Kind | Query |
| Permission | nexa.minecraft.java.read |
| Legal phases | Initialize, PostInitialize, Checkup, Finalize, Active |
| Idempotency | ReadOnly |
| Host status | Mapped in recorded snapshot |
Prepare a ZIP installation in a registered root’s runtime/plugin-<sha256> directory. Require Java major 8–99, matching host OS/architecture, an archive of 1–512 MiB, 1–8 HTTPS sources and a SHA-256 digest. Download.Target is replaced with a temporary Host-owned file grant. The review includes source, digest and the fact that Java will execute for probing. The owner rejects unsafe entries, caps extraction at 8,192 entries and 2 GiB total, probes exactly one bin/java executable, checks version/architecture and registers it with registry CAS. An unsuccessful registry CAS can leave a verified directory for explicit registration.
Request fields
| Field | Type | Meaning |
|---|---|---|
Distribution | JavaDistribution | Structured JavaDistribution value; follow its linked field contract. |
Target | RootRef | Structured RootRef value; follow its linked field contract. |
Successful result
Retain the exact plan ID and revision, review its bound inputs and confirmation requirement, then use the corresponding commit operation.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. A read-only classification does not bypass budgets or guarantee a failed request can be retried indefinitely. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_PrepareInstall(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_PrepareInstall_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
Install
| Property | Contract |
|---|---|
| Local SDK method ID | 10 |
| Kind | Operation |
| Permission | nexa.minecraft.java.write |
| Legal phases | Active |
| Idempotency | RequiredKey |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Plan | EntityId | Identity or revision in this model’s domain; preserve ownership and exact spelling. |
ExpectedRevision | Revision | Revision observed before this change. Preserve it exactly; a mismatch requires re-reading and reconciling the target. |
ConfirmationToken | string? | Domain value named by this field; additional accepted values and bounds are determined by the operation and Host policy. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Successful result
Work has been admitted. Read or watch the owned operation through Tasks to establish its terminal result; admission is not completion.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. Supply a key for the intended effect and retain that key and inputs while resolving an uncertain reply. Do not retry with changed inputs under the same key. Re-read after revision conflicts; cancellation does not prove rollback. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_Install(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_Install_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
Remove
| Property | Contract |
|---|---|
| Local SDK method ID | 11 |
| Kind | Operation |
| Permission | nexa.minecraft.java.write |
| Legal phases | Active |
| Idempotency | RequiredKey |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Id | EntityId | Identity in this model’s domain. Use the identity issued or declared for this object, not a display name or filesystem path. |
Successful result
Work has been admitted. Read or watch the owned operation through Tasks to establish its terminal result; admission is not completion.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. Supply a key for the intended effect and retain that key and inputs while resolving an uncertain reply. Do not retry with changed inputs under the same key. Re-read after revision conflicts; cancellation does not prove rollback. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_Remove(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_Remove_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
RegisterDistributionProvider
ProviderDescriptor → RegistrationRef
| Property | Contract |
|---|---|
| Local SDK method ID | 12 |
| Kind | Registration |
| Permission | nexa.minecraft.java.write |
| Legal phases | Initialize |
| Idempotency | RequiredKey |
| Host status | Mapped in recorded snapshot |
Register kind nexa:java/distributions with method ListDistributions: PageRequest → Page<JavaDistribution>. The current Host accepts verified ZIP distributions. Each entry identifies this provider and supplies OS, architecture, version, exact archive size and SHA-256. Multi-file Mojang offers continue to use ListManagedDistributions and PrepareManagedInstall.
Request fields
| Field | Type | Meaning |
|---|---|---|
Id | QualifiedId | Identity in this model’s domain. Use the identity issued or declared for this object, not a display name or filesystem path. |
Kind | QualifiedId | Host-supported provider family. Registration succeeds only for a mapped family. |
ContractVersion | ulong | Provider contract version; current catalog read-provider callbacks use 100. |
SchemaHash | string | Digest of the provider callback envelope schema; current catalog read providers use BusinessProviderCall. |
DisplayName | LocalizedText | User-facing localized label; it is not an authority-bearing identity. |
Capabilities | string[] | Exact capabilities advertised or required by this descriptor, subject to the Host’s accepted table. A bounded collection; do not assume an unbounded result or unspecified ordering. |
SupportedScopes | string[] | Scopes the provider declares it can handle; declaration does not authorize every target. A bounded collection; do not assume an unbounded result or unspecified ordering. |
Selection | SelectionPolicy | Selection rule; the current catalog callback boundary supports ExplicitRequest. |
Concurrency | ConcurrencyPolicy | Declared execution policy. A provider family may reject enum members whose semantics it does not implement. |
DeadlineMilliseconds | long | Requested deadline in milliseconds; queue time consumes this budget and caller deadlines can shorten it. |
FailurePolicy | ProviderFailurePolicy | How this provider family reports callback failures; it does not automatically make retries safe. |
Configuration | SchemaRef | Schema for provider configuration, not arbitrary executable Host configuration. |
Handler | ulong | Callback identifier registered by this plugin. A handler alone is not a public action or provider registration. |
Successful result
Retain the registration identity for the permitted update/release operation. Staged registrations become visible only at group activation.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. Supply a key for the intended effect and retain that key and inputs while resolving an uncertain reply. Do not retry with changed inputs under the same key. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_RegisterDistributionProvider(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_RegisterDistributionProvider_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
ListManagedDistributions
PageRequest → Page<ManagedJavaOffer> (wrapper, item)
| Property | Contract |
|---|---|
| Local SDK method ID | 13 |
| Kind | Query |
| Permission | nexa.minecraft.java.read |
| Legal phases | Active |
| Idempotency | ReadOnly |
| Host status | Mapped in recorded snapshot |
Request fields
| Field | Type | Meaning |
|---|---|---|
Cursor | string? | Opaque continuation or observation cursor. Reuse only in the issuing query/scope; absence and invalidity are different. Nullable; omission is distinct from an empty value. No implicit default is promised by this type. |
Limit | long | Requested bound on returned items. The Host may impose a smaller domain-specific limit. |
Successful result
Read Items and continue with NextCursor while preserving the original query. An absent cursor ends the sequence; an invalid cursor is an error.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. A read-only classification does not bypass budgets or guarantee a failed request can be retried indefinitely. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_ListManagedDistributions(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_ListManagedDistributions_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
PrepareManagedInstall
ManagedJavaInstallRequest → MutationPlan
| Property | Contract |
|---|---|
| Local SDK method ID | 14 |
| Kind | Query |
| Permission | nexa.minecraft.java.read |
| Legal phases | Active |
| Idempotency | ReadOnly |
| Host status | Mapped in recorded snapshot |
Use an offer returned by ListManagedDistributions. The managed offer describes the installer’s multi-file manifest; it is not interchangeable with the older JavaDistribution model.
Request fields
| Field | Type | Meaning |
|---|---|---|
Offer | EntityId | Identity or revision in this model’s domain; preserve ownership and exact spelling. |
ExpectedRevision | Revision | Revision observed before this change. Preserve it exactly; a mismatch requires re-reading and reconciling the target. |
Successful result
Retain the exact plan ID and revision, review its bound inputs and confirmation requirement, then use the corresponding commit operation.
Failure and retry
Unavailable capability, denied permission, wrong phase, malformed schema or foreign ownership fails the call. A read-only classification does not bypass budgets or guarantee a failed request can be retried indefinitely. Preserve structured errors; see recovery guidance.
C binding (call fragment; the caller supplies the encoded request and buffers):
nx_Minecraft_Java_PrepareManagedInstall(&reply, request, &options);The next resume receives the reply. Check nx_reply_success before nx_Minecraft_Java_PrepareManagedInstall_result. See the complete continuation example and Wasm ownership rules. This fragment is not a standalone guest.
Source: NexaCL-Plugin-SDK · Apache-2.0.