Class ObjectStoreInfo
-
- All Implemented Interfaces:
public final class ObjectStoreInfoInformation about an object in the object store
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classObjectStoreInfo.Companion
-
Field Summary
Fields Modifier and Type Field Description private final Stringbucketprivate final Stringnameprivate final Stringdescriptionprivate final Longsizeprivate final Integerchunksprivate final Stringdigestprivate final Instantmodifiedprivate final Booleandeletedprivate final Headersheadersprivate final ObjectStoreLinklinkpublic final static ObjectStoreInfo.CompanionCompanion
-
Constructor Summary
Constructors Constructor Description ObjectStoreInfo(String bucket, String name, String description, Long size, Integer chunks, String digest, Instant modified, Boolean deleted, Headers headers, ObjectStoreLink link)
-
Method Summary
Modifier and Type Method Description final StringgetBucket()The name of the bucket containing the object final StringgetName()The name of the object final StringgetDescription()Optional description of the object final LonggetSize()The size of the object in bytes final IntegergetChunks()The number of chunks the object is split into final StringgetDigest()The SHA-256 digest of the object final InstantgetModified()When the store recorded this revision, or nullwhen the value did not come from the server.final BooleangetDeleted()Whether the object is deleted final HeadersgetHeaders()Optional headers attached to the object final ObjectStoreLinkgetLink()What this entry points at, or nullwhen it holds its own bytes.-
-
Method Detail
-
getDescription
final String getDescription()
Optional description of the object
-
getModified
final Instant getModified()
When the store recorded this revision, or
nullwhen the value did not come from the server. eu.vstoyanov.natsy.jetstream.ObjectStore.info, eu.vstoyanov.natsy.jetstream.ObjectStore.list and eu.vstoyanov.natsy.jetstream.ObjectStore.watch read it off the stored metadata message and agree with each other (io/nats/client/api/ObjectInfo.java:56-58,:64-66,:74). The value eu.vstoyanov.natsy.jetstream.ObjectStore.put and eu.vstoyanov.natsy.jetstream.ObjectStore.delete hand back is the writing client's clock, stamped after the publish (io/nats/client/impl/NatsObjectStore.java:76), so it is close to the stored one rather than equal to it - re-read the object to compare timestamps with another writer.nullis what an ObjectInfo carrying no timestamp maps to; natsy does not stand in its own clock for one the server did not send.
-
getDeleted
final Boolean getDeleted()
Whether the object is deleted
-
getHeaders
final Headers getHeaders()
Optional headers attached to the object
-
getLink
final ObjectStoreLink getLink()
What this entry points at, or
nullwhen it holds its own bytes. An entry whose link ObjectStoreLink.isBucketLink cannot be read at all - there is no object there to read.
-
-
-
-