XPropertySetInfo objpsi = objps.getPropertySetInfo();
Property[] objprops = objpsi.getProperties();
Object oCopy = ((XMultiServiceFactory)tParam.getMSF()).createInstance(sname);
XPersistObject persCopy = (XPersistObject)
UnoRuntime.queryInterface(XPersistObject.class, oCopy);
persCopy.read(iStream);
XPropertySet copyps = (XPropertySet)UnoRuntime.queryInterface(
XPropertySet.class, oCopy);
XPropertySetInfo copypsi = copyps.getPropertySetInfo();
Property[] copyprops = copypsi.getProperties();
for (int i = 0; i < copyprops.length; i++) {
Object cps = copyps.getPropertyValue(copyprops[i].Name);
Object ops = objps.getPropertyValue(objprops[i].Name);
boolean locRes = ( (ValueComparer.equalValue(cps,ops)) ||
(utils.isVoid(cps) && utils.isVoid(ops)) );
//transient properties aran't stored
if (isTransient(objprops[i])) locRes = true;
Object pseudo = tEnv.getObjRelation("PSEUDOPERSISTENT");
if ( (pseudo != null) && !locRes) {
String str = copyprops[i].Name;
locRes = ( (str.equals("Time")) || (str.equals("Date"))
|| (str.equals("FormatsSupplier"))
|| (str.equals("Text"))
|| (str.equals("Value"))
|| (str.indexOf("UserDefined")>0)
);
}
if (!locRes) {
log.println("Property '" + copyprops[i].Name
+ "' failed");
dbg.printPropertyInfo(objps, objprops[i].Name, log);
dbg.printPropertyInfo(copyps, copyprops[i].Name, log);
}
bResult &= locRes;
}
} else {
Object oCopy = ((XMultiServiceFactory)tParam.getMSF()).createInstance(sname);
XPersistObject persCopy = (XPersistObject)
UnoRuntime.queryInterface(XPersistObject.class, oCopy);
persCopy.read(iStream);
bResult = ( persCopy.getServiceName().equals(sname) );
}
} catch (com.sun.star.uno.Exception e) {
log.println("Exception occured : ");