use of cbit.vcell.message.server.bootstrap.client.RemoteProxyVCellConnectionFactory.RemoteProxyException in project vcell by virtualcell.
the class ClientDocumentManager method addUserToGroup.
/**
* Insert the method's description here.
* Creation date: (11/28/00 5:43:44 PM)
* @param bioModelInfo cbit.vcell.biomodel.BioModelInfo
*/
public MathModelInfo addUserToGroup(MathModelInfo mathModelInfo, String userToAdd) throws DataAccessException {
try {
//
// publish from database
//
MathModelInfo newMathModelInfo = (MathModelInfo) addUserToGroup0(mathModelInfo, VersionableType.MathModelMetaData, mathModelInfoHash, userToAdd);
//
// delete MathModelMetaData from cache
//
xmlHash.remove(mathModelInfo.getVersion().getVersionKey());
fireDatabaseUpdate(new DatabaseEvent(this, DatabaseEvent.UPDATE, mathModelInfo, newMathModelInfo));
return newMathModelInfo;
} catch (RemoteProxyException e) {
handleRemoteProxyException(e);
throw new DataAccessException(e.getMessage());
}
}
use of cbit.vcell.message.server.bootstrap.client.RemoteProxyVCellConnectionFactory.RemoteProxyException in project vcell by virtualcell.
the class ClientDocumentManager method setGroupPrivate.
/**
* Insert the method's description here.
* Creation date: (11/28/00 5:43:44 PM)
* @param bioModelInfo cbit.vcell.biomodel.BioModelInfo
*/
public VCImageInfo setGroupPrivate(VCImageInfo imageInfo) throws DataAccessException {
try {
//
// unpublish from database
//
VCImageInfo newImageInfo = (VCImageInfo) setGroupPrivate0(imageInfo, VersionableType.VCImage, imgInfoHash);
//
// delete Image from cache
//
xmlHash.remove(imageInfo.getVersion().getVersionKey());
fireDatabaseUpdate(new DatabaseEvent(this, DatabaseEvent.UPDATE, imageInfo, newImageInfo));
return newImageInfo;
} catch (RemoteProxyException e) {
handleRemoteProxyException(e);
throw new DataAccessException(e.getMessage());
}
}
use of cbit.vcell.message.server.bootstrap.client.RemoteProxyVCellConnectionFactory.RemoteProxyException in project vcell by virtualcell.
the class ClientDocumentManager method setGroupPublic.
/**
* Insert the method's description here.
* Creation date: (11/28/00 5:43:44 PM)
* @param bioModelInfo cbit.vcell.biomodel.BioModelInfo
*/
public MathModelInfo setGroupPublic(MathModelInfo mathModelInfo) throws DataAccessException {
try {
//
// publish from database
//
MathModelInfo newMathModelInfo = (MathModelInfo) setGroupPublic0(mathModelInfo, VersionableType.MathModelMetaData, mathModelInfoHash);
//
// delete MathModelMetaData from cache
//
xmlHash.remove(mathModelInfo.getVersion().getVersionKey());
fireDatabaseUpdate(new DatabaseEvent(this, DatabaseEvent.UPDATE, mathModelInfo, newMathModelInfo));
return newMathModelInfo;
} catch (RemoteProxyException e) {
handleRemoteProxyException(e);
throw new DataAccessException(e.getMessage());
}
}
use of cbit.vcell.message.server.bootstrap.client.RemoteProxyVCellConnectionFactory.RemoteProxyException in project vcell by virtualcell.
the class ClientDocumentManager method setGroupPublic.
/**
* Insert the method's description here.
* Creation date: (11/28/00 5:43:44 PM)
* @param bioModelInfo cbit.vcell.biomodel.BioModelInfo
*/
public BioModelInfo setGroupPublic(BioModelInfo bioModelInfo) throws DataAccessException {
try {
//
// publish from database
//
BioModelInfo newBioModelInfo = (BioModelInfo) setGroupPublic0(bioModelInfo, VersionableType.BioModelMetaData, bioModelInfoHash);
//
// delete BioModelMetaData from cache
//
xmlHash.remove(bioModelInfo.getVersion().getVersionKey());
fireDatabaseUpdate(new DatabaseEvent(this, DatabaseEvent.UPDATE, bioModelInfo, newBioModelInfo));
return newBioModelInfo;
} catch (RemoteProxyException e) {
handleRemoteProxyException(e);
throw new DataAccessException(e.getMessage());
}
}
use of cbit.vcell.message.server.bootstrap.client.RemoteProxyVCellConnectionFactory.RemoteProxyException in project vcell by virtualcell.
the class ClientDocumentManager method saveAsNew.
/**
* Insert the method's description here.
* Creation date: (1/19/01 11:27:52 AM)
*/
public BioModel saveAsNew(BioModel bioModel, java.lang.String newName, String[] independentSims) throws DataAccessException {
try {
String bioModelXML = null;
try {
bioModel.getVCMetaData().cleanupMetadata();
bioModelXML = XmlHelper.bioModelToXML(bioModel);
} catch (XmlParseException e) {
e.printStackTrace(System.out);
throw new DataAccessException(e.getMessage());
}
String savedBioModelXML = sessionManager.getUserMetaDbServer().saveBioModelAs(new BigString(bioModelXML), newName, independentSims).toString();
BioModel savedBioModel = getBioModelFromDatabaseXML(new XMLHolder<BioModel>(savedBioModelXML));
KeyValue savedKey = savedBioModel.getVersion().getVersionKey();
if (xmlHash.get(savedKey) == null) {
xmlHash.put(savedKey, savedBioModelXML);
}
BioModelInfo savedBioModelInfo = new BioModelInfo(savedBioModel.getVersion(), savedBioModel.getModel().getKey(), savedBioModel.createBioModelChildSummary(), VCellSoftwareVersion.fromSystemProperty());
bioModelInfoHash.put(savedKey, savedBioModelInfo);
SimulationContext[] scArr = savedBioModel.getSimulationContexts();
for (int i = 0; i < scArr.length; i++) {
updateGeometryRelatedHashes(scArr[i].getGeometry());
}
fireDatabaseInsert(new DatabaseEvent(this, DatabaseEvent.INSERT, null, savedBioModelInfo));
return savedBioModel;
} catch (RemoteProxyException e) {
e.printStackTrace(System.out);
throw new DataAccessException(VCellErrorMessages.FAIL_SAVE_MESSAGE + "\n\n" + e.getMessage());
}
}
Aggregations