Annotation Interface NotOwning

@Retention(CLASS) @Documented @Target({TYPE,PARAMETER,METHOD,FIELD}) public @interface NotOwning
This annotation allows to specify absence of responsibility for certain objects as they are passed from one method to another.

This annotation is the direct inverse of Owning and can be used in all locations, where that annotation is used. @NotOwning can be used do specify a shared responsibility rather than the clear separation between sources and sinks of resources given by Owning.

In particular the annotation @NotOwning makes explicit that absence of @Owning is by intention.

Additionally, placing @NotOwning on a class that implements AutoCloseable specifies that instances of this class do not hold any gc-resistant resources and therefore calling AutoCloseable.close() is not necessary.