Java client API · v0.0.8
This page inventories every public type and method in the v0.0.8 client package. The task pages explain use and failure behavior. Package-private XML, JSON, and signing helpers are implementation details.
Builder
ObjectStorageClientBuilder has a public no-argument constructor. Each setter returns the builder.
| Method | Purpose |
|---|---|
endpoint(URI) | Set the endpoint origin; required. |
region(String) | Set the signing region; default us-east-1. |
credentials(String, String) | Set access and secret keys; required. |
timeout(Duration) | Set a positive per-request timeout; default 30 seconds. |
allowInsecureHttp() | Permit HTTP for a trusted local endpoint. |
build() | Validate settings and create an independent ObjectStorageClient. |
See Install & connect for endpoint rules and an example.
ObjectStorageClient
| Method | Result / effect |
|---|---|
getObject(bucket, key) | Open ObjectData; caller closes it. |
headObject(bucket, key) | Read ObjectMetadata without body bytes. |
putObject(bucket, key, byte[], contentType) | Single-request byte-array upload. |
putObject(bucket, key, Path, contentType) | Hash then upload a file. |
deleteObject(bucket, key) | Delete the current object. |
listObjects(bucket, prefix, continuationToken, maxKeys) | One ObjectPage. |
createMultipartUpload(bucket, key, contentType) | Start and return a MultipartUpload. |
uploadPart(upload, partNumber, byte[]) | Send one part and return its Part with ETag. |
uploadFileParts(upload, Path, partSize) | Sequential file parts; returns List<Part> without completing. |
listParts(upload, partNumberMarker, maxParts) | One PartPage. |
completeMultipartUpload(upload, List<Part>) | Complete and return the object ETag. |
abortMultipartUpload(upload) | Abort an unfinished session. |
listMultipartUploads(bucket, prefix, keyMarker, uploadIdMarker, maxUploads) | One MultipartUploadPage. |
getBucketAcl(bucket) | Read AclPolicy. |
getObjectAcl(bucket, key) | Read AclPolicy. |
putBucketAcl(bucket, AclPolicy) | Replace bucket ACL. |
putObjectAcl(bucket, key, AclPolicy) | Replace object ACL. |
getCapabilities() | Read manifest or report observed support. |
probeReadOnlyCapabilities(bucket, existingObjectKey) | Opt into read-only probes. |
close() | Close the underlying HTTP client. |
Read Objects & listings, Multipart uploads, ACLs, and Capabilities for the method contracts.
Result records
Record components are also their public accessor names.
| Type | Components |
|---|---|
ObjectData | body, length, contentType, etag; also close() |
ObjectMetadata | length, contentType, etag |
ObjectEntry | key, size, etag |
ObjectPage | objects, nextContinuationToken |
MultipartUpload | bucket, key, uploadId |
Part | number, etag, size |
PartPage | parts, truncated, nextPartNumberMarker |
MultipartUploadPage | uploads, truncated, nextKeyMarker, nextUploadIdMarker |
The records have public constructors. Page records copy their lists. MultipartUpload validates its bucket, key, and ID; Part validates its number, ETag, and size.
ACL and capability types
| Type | Public members |
|---|---|
AclPolicy | Record with ownerId, grants; GranteeType enum (CANONICAL_USER, GROUP); Permission enum (READ, WRITE, READ_ACP, WRITE_ACP, FULL_CONTROL) |
AclPolicy.Grant | Record with type, grantee, permission |
Capabilities | Record with service, operations, limits, serviceVersion, storageMode, completeOperationInventory; two public constructors and support(String) |
Capabilities.ServiceKind | OBJECTSTORE, UNKNOWN_S3 |
Capabilities.Support | SUPPORTED, UNSUPPORTED, UNKNOWN |
Exceptions
ObjectStorageException, TransportException, and ProtocolException are public IOException subclasses. ObjectStorageException exposes statusCode(), errorCode(), requestId(), and retryable(). Their constructors are package-private; callers inspect and catch them. See Errors & lifecycle.