T - the kind of object that is sharedpublic interface SharedExtension<T> extends Iterable<T>
SharedExtension is a set of extensions shared by many clients. Basically it is used for
optimization, as it allows to reuse objects. Clients should call bind() before, and
unbind() after using a SharedExtension object.| Modifier and Type | Method and Description |
|---|---|
void |
bind()
Needs to be called by clients to make sure that
get() actually returns something. |
List<T> |
get()
Gets the list of shared objects.
|
ExtensionName<T> |
getName()
Gets the name of the extension whose objects are shared.
|
void |
unbind()
Can be called by clients to release no longer needed resources.
|
forEach, iterator, spliteratorvoid bind()
get() actually returns something.void unbind()
ExtensionName<T> getName()
nullList<T> get()
null, is not modifiableIllegalStateException - if this SharedExtension is not boundCopyright © 2017 Docking Frames. All rights reserved.