public abstract class SyncBeanBase
extends java.lang.Object
UserSyncBean
and OrganizationSyncBean
. These sync beans are used to access user and organization
data respectively. The sync beans make use of sync helper data object classes, that extend from DOBase
,
and are used to read from and write to the WebSphere Commerce database tables.
VMMProxy
is used to read from and write to LDAP.
If WebSphere Commerce is configured to use its own database as the master member profile
repository, then the sync beans will only interact with WebSphere Commerce member tables. If on the other
hand, WebSphere Commerce is configured to use an LDAP server as the master profile repository, the sync
beans will persist member data to LDAP as well as the WebSphere Commerce database. During a read operation,
the sync bean's properties are first populated based on the data in the database. Then, if the data on
the LDAP server has been updated since the last synchronization, any LDAP properties that are configured
to be synchronized will overwrite the existing property values. The ldapentry.xml
configuration file controls which properties are synchronized between WebSphere Commerce and LDAP, and in
which direction:
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
COPYRIGHT
The IBM Copyright notice field.
|
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
getCommerceDN(java.lang.String astrLDAPDN,
commonj.sdo.DataObject adoMember)
Gets the Commerce DN corresponding to the given LDAP DN.
|
static java.lang.String |
getLDAPDN(java.lang.String astrCommerceDN)
Gets the LDAP DN corresponding to the given Commerce DN.
|
commonj.sdo.DataObject |
getLDAPMember()
Gets the entity data object corresponding to the member in LDAP.
|
java.lang.String |
getMemberId()
Gets the member ID that corresponds to this sync bean.
|
short |
getMemberType()
Gets the member type:
|
TypedProperty |
getProperties()
Gets the properties of the sync bean.
|
java.lang.String |
getProperty(java.lang.String strAttributeName)
Gets the value of the specified attribute.
|
java.util.Vector |
getProperty(java.lang.String strAttributeName,
java.lang.String strStoreEntityId)
Gets a vector of member attribute values based on the attribute name and store ID.
|
com.ibm.commerce.member.objects.WMMMapAccessBean |
getWMMMapAccessBean()
Get the
WMMMap access bean that corresponds to the row in the WMMMAP
table for this sync bean. |
static boolean |
isWMMEnabled()
Deprecated.
in WC 7.0, replaced by
MemberHelper.isLDAPUsedForProfileStorage() |
void |
refresh()
Refresh the bean by first getting the values from the database.
|
void |
update(TypedProperty tpUpdate)
Updates data in the sync bean, and then persists it to the Commerce database and LDAP.
|
public static final java.lang.String COPYRIGHT
public static boolean isWMMEnabled()
MemberHelper.isLDAPUsedForProfileStorage()
ProfileDataStorage
flag in the instance
configuration file.public java.lang.String getMemberId()
public commonj.sdo.DataObject getLDAPMember()
public com.ibm.commerce.member.objects.WMMMapAccessBean getWMMMapAccessBean()
WMMMap
access bean that corresponds to the row in the WMMMAP
table for this sync bean.public short getMemberType()
ECMemberCommandParameterConstants.MEMBER_TYPE_UNKNOWN
= -1
ECMemberCommandParameterConstants.MEMBER_TYPE_PERSON
= 0
ECMemberCommandParameterConstants.MEMBER_TYPE_GROUP
= 1
ECMemberCommandParameterConstants.MEMBER_TYPE_ORGANIZATION
= 2
ECMemberCommandParameterConstants.MEMBER_TYPE_ORGANIZATIONAL_UNIT
= 3
public TypedProperty getProperties()
public java.lang.String getProperty(java.lang.String strAttributeName)
strAttributeName
- The name of the attribute to be retrieved.public java.util.Vector getProperty(java.lang.String strAttributeName, java.lang.String strStoreEntityId)
strAttributeName
- The attribute name to be retrieved.strStoreEntityId
- The store ID context.public void refresh() throws java.rmi.RemoteException, ECException
UserSyncBean
. This method
is called during find and update scenarios, but not during create.java.rmi.RemoteException
ECException
public void update(TypedProperty tpUpdate) throws java.rmi.RemoteException, javax.persistence.NoResultException, ECException
tpUpdate
- Update properties.java.rmi.RemoteException
javax.persistence.NoResultException
ECException
public static java.lang.String getCommerceDN(java.lang.String astrLDAPDN, commonj.sdo.DataObject adoMember) throws ECException
LDAPIntegrationCmd.getCommerceDN(String, DataObject)
.astrLDAPDN
- The LDAP DN.adoMember
- The entity object representing the member.ECException
- Thrown if an error occurs.public static java.lang.String getLDAPDN(java.lang.String astrCommerceDN) throws ECException
LDAPIntegrationCmd.getLDAPDN(String)
.astrCommerceDN
- The Commerce DN.ECException
- Thrown if an error occurs.