Top Description Methods
io.netty5.util

public Interface SafeCloseable

extends AutoCloseable
Known Direct Subinterfaces
io.netty5.util.Send

A SafeCloseable can be safely closed without risk of an exception being thrown.

This interface extends AutoCloseable so instances can be used in try-with-resources clauses.

Implementation Note

Similar to java.io.Closeable, implementors should make their close() idempotent. In other words, it should be safe to call close() multiple times on the same instance. This is a restriction beyond what AutoCloseable provides.

Method Summary

Modifier and TypeMethod and Description
public void
close()

Redeclares java.lang.AutoCloseable.close.

Closes this resource, relinquishing any underlying resources.

Method Detail

closeback to summary
public void close()

Redeclares java.lang.AutoCloseable.close.

Doc from java.lang.AutoCloseable.close.

Closes this resource, relinquishing any underlying resources. This method is invoked automatically on objects managed by the try-with-resources statement.

Annotations
@Override