Package org.wildfly.common.ref
Class StrongReference<T,A>
java.lang.Object
org.wildfly.common.ref.StrongReference<T,A>
- Type Parameters:
T- the reference value typeA- the attachment type
- All Implemented Interfaces:
Reference<T,A>
@Deprecated(forRemoval=true)
public class StrongReference<T,A>
extends Object
implements Reference<T,A>
Deprecated, for removal: This API element is subject to removal in a future version.
A strong reference with an attachment. Since strong references are always reachable, a reaper may not be used.
- Author:
- David M. Lloyd
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.wildfly.common.ref.Reference
Reference.Type -
Constructor Summary
ConstructorsConstructorDescriptionStrongReference(T referent) Deprecated, for removal: This API element is subject to removal in a future version.Construct a new instance.StrongReference(T referent, A attachment) Deprecated, for removal: This API element is subject to removal in a future version.Construct a new instance. -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Deprecated, for removal: This API element is subject to removal in a future version.Clear the reference.get()Deprecated, for removal: This API element is subject to removal in a future version.Get the value, ornullif the reference has been cleared.Deprecated, for removal: This API element is subject to removal in a future version.Get the attachment, if any.getType()Deprecated, for removal: This API element is subject to removal in a future version.Get the type of the reference.toString()Deprecated, for removal: This API element is subject to removal in a future version.
-
Constructor Details
-
StrongReference
Deprecated, for removal: This API element is subject to removal in a future version.Construct a new instance.- Parameters:
referent- the referentattachment- the attachment
-
StrongReference
Deprecated, for removal: This API element is subject to removal in a future version.Construct a new instance.- Parameters:
referent- the referent
-
-
Method Details
-
get
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:ReferenceGet the value, ornullif the reference has been cleared. -
clear
public void clear()Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:ReferenceClear the reference. -
getAttachment
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:ReferenceGet the attachment, if any.- Specified by:
getAttachmentin interfaceReference<T,A> - Returns:
- the attachment
-
getType
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from interface:ReferenceGet the type of the reference. -
toString
Deprecated, for removal: This API element is subject to removal in a future version.
-
StrongReferenceinstead.