setParentRegId(null != reg.getParent() ? reg.getParent().getRegistrationId() : null);
setSubscriptions(reg.getSubscriptions());
if (reg instanceof DatabusMultiPartitionRegistration)
{
DatabusMultiPartitionRegistration mpReg = (DatabusMultiPartitionRegistration) reg;
setMultiPartition(true);
ArrayList<RegistrationId> childrenRegs =
new ArrayList<RegistrationId>(mpReg.getPartitions().size());
for (Map.Entry<DbusPartitionInfo, DatabusRegistration> child : mpReg.getPartitionRegs()
.entrySet())
{
childrenRegs.add(child.getValue().getRegistrationId());
}
setChildrenRegistrations(childrenRegs);