|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.vbs.spring.versioning.VersionDependentBean
public final class VersionDependentBean
Wrapper for each Spring bean annotated as a
VersionDependentClass.
| Constructor Summary | |
|---|---|
VersionDependentBean(java.lang.Object bean,
java.lang.String beanName)
Creates a wrapper for a Spring bean annotated as a VersionDependentClass. |
|
| Method Summary | |
|---|---|
(package private) boolean |
checkDuplicateBeanType(VersionDependentBean other)
Returns true if this bean is of the same underlying type as that of the other bean. |
boolean |
equals(java.lang.Object obj)
|
(package private) java.lang.Object |
getBean()
Returns the Spring bean. |
java.lang.String |
getBeanName()
Returns the name of the bean within the application context. |
java.lang.String[] |
getImplementedVersions()
Returns the array of version identifiers that this bean implements. |
java.lang.Class<?> |
getTargetClass()
Returns the underlying class of the Spring bean. |
int |
hashCode()
|
boolean |
isImplementationFor(java.lang.String versionedBeanName)
Returns true if this is the version dependent implementation for the versioned bean, used when beans have been wired by name. |
boolean |
isImplementingVersion(java.lang.String activeVersion)
Returns true if this implements the active version. |
boolean |
isUniqueForType()
Returns true if this is the only bean configured for the bean's class. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
VersionDependentBean(java.lang.Object bean,
java.lang.String beanName)
VersionDependentClass.
bean - the Spring bean.beanName - the name of the bean within the application context.| Method Detail |
|---|
public java.lang.String[] getImplementedVersions()
Obtained from the VersionDependentClass annotation.
java.lang.Object getBean()
public java.lang.String getBeanName()
public java.lang.Class<?> getTargetClass()
The bean may have been proxied or enhanced.
boolean checkDuplicateBeanType(VersionDependentBean other)
isUniqueForType method
will return false.
other - another VersionDependentBean
public boolean isUniqueForType()
public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Objectpublic boolean isImplementationFor(java.lang.String versionedBeanName)
If this implementation is for a single version, then the name of this bean must be of the format versionedBeanName + versionId.
If this implementation is for multiple versions, then the name of this bean must be of the format versionedBeanName + versionid1_versionid2 etc (each version being separated by an underscore).
versionedBeanName - the name of the versioned bean within the application context.
public boolean isImplementingVersion(java.lang.String activeVersion)
activeVersion - the active version.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||