Package org.opengda.lde.utils
Class LDEResourceUtil
java.lang.Object
org.opengda.lde.utils.LDEResourceUtil
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetCells()return the default file directory.returns the default filename.org.eclipse.emf.edit.domain.EditingDomaingetExperiments(String filename) getExperiments(org.eclipse.emf.ecore.resource.Resource res) org.eclipse.emf.ecore.resource.Resourcereturn the resource.org.eclipse.emf.ecore.resource.ResourcegetResource(String fileName) getSamples(String filename) getSamples(Cell cell) getStages(Experiment experiment) voidsave(org.eclipse.emf.ecore.resource.Resource res) voidvoidsetFileName(String fileName) enable file name to be set in Spring object configuration.
-
Constructor Details
-
LDEResourceUtil
public LDEResourceUtil()
-
-
Method Details
-
getDefaultFilename
returns the default filename.- Returns:
-
getDefaultDirectory
return the default file directory. This directory must have permission for GDA client to write to. At DLS beamlines it is always the 'xml' directory under the directory defined by the java propertygda.data.scan.datawriter.datadir. In other case, such as on developer's PC, or if this property is not set, it will use systemuse.homeproperty to store the file.- Returns:
-
getFileName
-
setFileName
enable file name to be set in Spring object configuration. If the file name dosn't contain full path, the default XML data directory defined in java propertygda.data.scan.datawriter.datadiris used.- Parameters:
fileName-
-
getResource
return the resource. The filename for this resource can be set in Spring object configuration property. If not set in Spring configuration, it is built using GDA propertygda.data.scan.datawriter.datadirand the default file namenewsamples.lde. If this property is not set this sequence file will be created atuser.home- Returns:
- Throws:
Exception
-
getExperiments
- Throws:
Exception
-
createExperiments
- Throws:
Exception
-
getExperiments
- Throws:
Exception
-
getResource
-
getExperiments
-
getStages
-
getCells
-
getSamples
-
save
- Throws:
IOException
-
saveAs
-
getEditingDomain
public org.eclipse.emf.edit.domain.EditingDomain getEditingDomain() -
getSamples
- Throws:
Exception
-
getStages
- Throws:
Exception
-
getCells
- Throws:
Exception
-
getSamples
- Throws:
Exception
-
getStages
- Throws:
Exception
-
getCells
- Throws:
Exception
-