}
if (vobj2jv.containsKey(vobj.getVorbaId())
- && !((VorbaId) vobj2jv.get(vobj.getVorbaId())).equals(jvobj))
+ && !(vobj2jv.get(vobj.getVorbaId())).equals(jvobj))
{
Cache.log.debug(
"Warning? Overwriting existing vamsas id binding for "
{
throw new Error("Implementation Error: Vamsas Document Class "+vobj.getClass()+" should bind to a "+boundType+" (found a "+jvobj.getClass()+")");
}
+ dsReg.registerDsObj(this);
}
/**
* construct and initialise datastore object and retrieve document object bound to Jalview object jvobj2 and validate it against boundType
{
throw new Error("Implementation Error: Jalview Class "+jvobj2.getClass()+" should bind to a "+boundToType+" (found a "+vobj.getClass()+")");
}
+ dsReg.registerDsObj(this);
}
/**
* create a new vobj to be added to the document
*/
protected void doSync()
{
-
+ dsReg.registerDsObj(this);
if (vobj == null)
{
log.debug("adding new vobject to document.");
*/
protected void doJvUpdate()
{
+ dsReg.registerDsObj(this);
if (jvobj == null)
{
log.debug("adding new vobject to Jalview from Document");
*/
protected Object jvobj = null;
+ protected DatastoreRegistry dsReg;
+
public void initDatastoreItem(VamsasAppDatastore ds)
{
datastore = ds;
+ dsReg = ds.getDatastoreRegisty();
initDatastoreItem(ds.getProvEntry(), ds.getClientDocument(), ds
.getVamsasObjectBinding(), ds.getJvObjectBinding());
}
- public void initDatastoreItem(Entry provEntry, IClientDocument cdoc,
+ private void initDatastoreItem(Entry provEntry, IClientDocument cdoc,
Hashtable vobj2jv, IdentityHashMap jv2vobj)
{
this.provEntry = provEntry;
return jvobj;
}
+ public boolean docWasUpdated()
+ {
+ return (this.addtodoc || this.updated) && this.success;
+ }
+
+ public boolean jvWasUpdated()
+ {
+ return (success); // TODO : Implement this properly!
+ }
+
}