* connection info then calls back to user-defined policy.
*/
protected SliceInfo findSliceNames(OpenJPAStateManager sm, Object edata) {
if (SliceImplHelper.isSliceAssigned(sm))
return SliceImplHelper.getSliceInfo(sm);
SliceInfo result = null;
PersistenceCapable pc = sm.getPersistenceCapable();
Object ctx = getContext();
if (_conf.isReplicated(sm.getMetaData().getDescribedType())) {
result = SliceImplHelper.getSlicesByPolicy(pc, _conf, ctx);
} else {
String origin = estimateSlice(sm, edata);
if (origin == null) {
result = SliceImplHelper.getSlicesByPolicy(pc, _conf, ctx);
} else {
result = new SliceInfo(origin);
}
}
return result;
}