public abstract class AbstractResourceRegistration extends java.lang.Object implements ResourceRegistration
ResourceRegistration
interface.
Implemented predicates like the current registration status are obtained
directly from the core using the underlying resource or resource's data.Modifier | Constructor and Description |
---|---|
protected |
AbstractResourceRegistration()
Constructor for use by subclasses.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o)
Compares the specified object with this resource registration
for equality.
|
<A extends java.lang.annotation.Annotation> |
getAnnotation(java.lang.Class<A> type) |
java.util.List<java.lang.annotation.Annotation> |
getAnnotations() |
boolean |
hasAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> type) |
int |
hashCode()
Returns the hash code value for this resource registration.
|
boolean |
isProvided()
Returns
true if the underlying registrable
object is provided by an object provider, false otherwise. |
boolean |
isRegistered()
Returns
true if the underlying registrable
object is currently registered, false otherwise. |
java.lang.String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getListenerType, getResource, getResourceName
getAnnotation, getAnnotations, hasAnnotation
protected AbstractResourceRegistration()
public final boolean equals(@Nullable java.lang.Object o)
true
if the specified object is also
a resource registration and the two registrations have the same listener
type and resource name. This definition ensures that this method works
properly across different implementations of the resource registration
interface.equals
in interface ResourceRegistration
equals
in class java.lang.Object
o
- an object to be compared for equality
with this resource registrationtrue
if the specified object is equal to
this resource registration, false
otherwisepublic final int hashCode()
Objects.hash(Object...)
for
listener type and resource name.hashCode
in interface ResourceRegistration
hashCode
in class java.lang.Object
public final java.lang.String toString()
toString
in class java.lang.Object
public final boolean isRegistered()
true
if the underlying registrable
object is currently registered, false
otherwise.isRegistered
in interface Registration
public final boolean isProvided()
true
if the underlying registrable
object is provided by an object provider, false
otherwise.isProvided
in interface Registration
public final boolean hasAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> type)
hasAnnotation
in interface Annotable
public final <A extends java.lang.annotation.Annotation> A getAnnotation(java.lang.Class<A> type)
getAnnotation
in interface Annotable
public final java.util.List<java.lang.annotation.Annotation> getAnnotations()
getAnnotations
in interface Annotable