Package export.RExport
Class RExportManager
java.lang.Object
export.RExport.RExportManager
- All Implemented Interfaces:
PamDataUnitExporter
Handles exporting pam data units into an rdata.
- Author:
- Jamie Macaulay
-
Nested Class Summary
Modifier and TypeClassDescriptionclass
Simple class to hold RData and list of the data unit names whihc were saved. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Close the exporter.dataUnits2R
(List<PamDataUnit> dataUnits) Sort a list of data units into lists of the same type of units.dataUnits2R
(List<PamDataUnit> dataUnits, String name, org.renjin.sexp.PairList.Builder allData) Sort a list of data units into lists of the same type of units.boolean
exportData
(File fileName, List<PamDataUnit> dataUnits, boolean append) Export the data to a folder.Get the extension for the output file typeGet the ikonli icon string for the exporter.getName()
Get the name of the exporter.javafx.scene.layout.Pane
An optional JavaFX pane that displays additional options for the user.An optional panel that displays additional options for the user.boolean
hasCompatibleUnits
(Class dataUnitType) Check whether a particular data unit class is compatibleboolean
hasCompatibleUnits
(List<PamDataUnit> dataUnits) Check whether there are compatible data units to be exported.boolean
Check whether and exporter needs a new filevoid
Called whenever a new export run is prepared.
-
Constructor Details
-
RExportManager
-
-
Method Details
-
exportData
Description copied from interface:PamDataUnitExporter
Export the data to a folder.- Specified by:
exportData
in interfacePamDataUnitExporter
- Parameters:
fileName
- - the file to export todataUnits
- - the data units to export.- Returns:
- true if exported successfully.
-
hasCompatibleUnits
Check whether there are compatible data units to be exported.- Parameters:
dataUnits
- - the data unit list- Returns:
- true if r export is possible for the current data units.
-
hasCompatibleUnits
Description copied from interface:PamDataUnitExporter
Check whether a particular data unit class is compatible- Specified by:
hasCompatibleUnits
in interfacePamDataUnitExporter
- Parameters:
dataUnitType
- - the data unit type to test.- Returns:
- true if it can be exported.
-
dataUnits2R
Sort a list of data units into lists of the same type of units. Convert to a list of structures.- Parameters:
dataUnits
- - a list of data units to convert to matlab structures.- Returns:
- list of list of R strucutures ready for saving to .RData file.
-
dataUnits2R
public RExportManager.RData dataUnits2R(List<PamDataUnit> dataUnits, String name, org.renjin.sexp.PairList.Builder allData) Sort a list of data units into lists of the same type of units. Convert to a list of structures.- Parameters:
dataUnits
- - a list of data units to convert to matlab structures.- Returns:
- list of list of R strucutures ready for saving to .RData file.
-
getFileExtension
Description copied from interface:PamDataUnitExporter
Get the extension for the output file type- Specified by:
getFileExtension
in interfacePamDataUnitExporter
- Returns:
- the extension for the file type e.g. "mat"
-
getIconString
Description copied from interface:PamDataUnitExporter
Get the ikonli icon string for the exporter.- Specified by:
getIconString
in interfacePamDataUnitExporter
- Returns:
- the ikon string.
-
getName
Description copied from interface:PamDataUnitExporter
Get the name of the exporter.- Specified by:
getName
in interfacePamDataUnitExporter
- Returns:
- the name of the exporter.
-
close
public void close()Description copied from interface:PamDataUnitExporter
Close the exporter.- Specified by:
close
in interfacePamDataUnitExporter
-
isNeedsNewFile
public boolean isNeedsNewFile()Description copied from interface:PamDataUnitExporter
Check whether and exporter needs a new file- Specified by:
isNeedsNewFile
in interfacePamDataUnitExporter
- Returns:
- true if we need a new file.
-
getOptionsPanel
Description copied from interface:PamDataUnitExporter
An optional panel that displays additional options for the user.- Specified by:
getOptionsPanel
in interfacePamDataUnitExporter
- Returns:
- additional options panel - can be null.
-
getOptionsPane
public javafx.scene.layout.Pane getOptionsPane()Description copied from interface:PamDataUnitExporter
An optional JavaFX pane that displays additional options for the user.- Specified by:
getOptionsPane
in interfacePamDataUnitExporter
- Returns:
- pane with additonal options - can be null.
-
prepareExport
public void prepareExport()Description copied from interface:PamDataUnitExporter
Called whenever a new export run is prepared.- Specified by:
prepareExport
in interfacePamDataUnitExporter
-