Record Class PublicRepositoryGateway.Content
java.lang.Object
java.lang.Record
zeroecho.pki.server.PublicRepositoryGateway.Content
- Record Components:
lease- content lease owned by this descriptormediaType- response media typeetag- response entity tagcacheClass- cache policy
- All Implemented Interfaces:
AutoCloseable
- Enclosing class:
PublicRepositoryGateway
public static record PublicRepositoryGateway.Content(PkiRepositoryContent lease, String mediaType, String etag, PublicRepositoryGateway.CacheClass cacheClass)
extends Record
implements AutoCloseable
Lifecycle-owned binary response descriptor.
-
Constructor Summary
ConstructorsConstructorDescriptionContent(PkiRepositoryContent lease, String mediaType, String etag, PublicRepositoryGateway.CacheClass cacheClass) Validates response metadata. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecacheClassrecord component.voidclose()Closes the underlying immutable-content lease.final booleanIndicates whether some other object is "equal to" this one.etag()Returns the value of theetagrecord component.final inthashCode()Returns a hash code value for this object.lease()Returns the value of theleaserecord component.Returns the value of themediaTyperecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Content
public Content(PkiRepositoryContent lease, String mediaType, String etag, PublicRepositoryGateway.CacheClass cacheClass) Validates response metadata.
-
-
Method Details
-
close
Closes the underlying immutable-content lease.- Specified by:
closein interfaceAutoCloseable- Throws:
IOException
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
lease
-
mediaType
-
etag
-
cacheClass
Returns the value of thecacheClassrecord component.- Returns:
- the value of the
cacheClassrecord component
-