$darkmode
DENOPTIM
|
File formats identified by DENOPTIM. More...
Classes | |
enum | DataKind |
The kind of data found in a file. More... | |
Public Member Functions | |
boolean | isFolder () |
String | getSampleEndRegex () |
In identifying a text file we read as many lines as possible until we match the "end-of-sample" string. More... | |
Set< String > | getDefiningRegex () |
Returns the list of regex strings that allow identification of a file. More... | |
Set< String > | getNegatingRegex () |
Returns the list of regex strings that exclude a file format. More... | |
String | getExtension () |
Static Public Member Functions | |
[static initializer] | |
static FileFormat | fromString (String extension, DataKind kind) |
Gets the FileFormat from file extension and kind of data. More... | |
static FileFormat[] | getSDFFormats () |
Returns the collection of file formats using SDF syntax. More... | |
static FileFormat[] | getParameterFormats () |
Returns the collection of file formats with input parameters. More... | |
static FileFormat[] | getTXTFormats () |
Returns the collection of file formats restricted to TXT files (excluded parameter files) More... | |
Private Attributes | |
String | extension = "" |
Set< String > | definingRegex = new HashSet<String>() |
Collection of regex that, if matched, suggests assigning the format to a specific FileFormat. More... | |
Set< String > | negatingRegex = new HashSet<String>() |
Collection of regex that, if matched, prevents assigning the format to a specific FileFormat. More... | |
String | endOfSampleRegex = null |
Regex used to identify the end of the sampled text used to determine the format of a file. More... | |
Boolean | isFolder = false |
File formats identified by DENOPTIM.
Definition at line 32 of file FileFormat.java.
|
static |
References denoptim.constants.DENOPTIMConstants.APSTAG, denoptim.programs.RunTimeParameters.ParametersType.CEBL_PARAMS, denoptim.constants.DENOPTIMConstants.FITNESSTAG, denoptim.programs.RunTimeParameters.ParametersType.FR_PARAMS, denoptim.programs.RunTimeParameters.ParametersType.FRG_PARAMS, denoptim.programs.RunTimeParameters.ParametersType.GA_PARAMS, denoptim.constants.DENOPTIMConstants.GAGENSUMMARYHEADER, denoptim.programs.RunTimeParameters.ParametersType.GE_PARAMS, denoptim.programs.RunTimeParameters.ParametersType.GLH_PARAMS, denoptim.programs.RunTimeParameters.ParametersType.GO_PARAMS, denoptim.constants.DENOPTIMConstants.GRAPHJSONTAG, denoptim.constants.DENOPTIMConstants.GRAPHTAG, denoptim.programs.RunTimeParameters.ParametersType.ISO_PARAMS, denoptim.programs.RunTimeParameters.ParametersType.MMB_PARAM, denoptim.constants.DENOPTIMConstants.MOLERRORTAG, denoptim.constants.DENOPTIMConstants.UNIQUEIDTAG, and denoptim.constants.DENOPTIMConstants.VERTEXJSONTAG.
|
static |
Gets the FileFormat from file extension and kind of data.
extension | the extension of the file (i.e., in blabla.ext the extension is ext ). |
kind | the kind of data contained in the file. |
Definition at line 246 of file FileFormat.java.
Referenced by denoptim.gui.GUIFileSaver.pickFileForSavingGraphs(), and denoptim.gui.GUIFileSaver.pickFileForSavingVertexes().
Set< String > denoptim.files.FileFormat.getDefiningRegex | ( | ) |
Returns the list of regex strings that allow identification of a file.
Definition at line 427 of file FileFormat.java.
String denoptim.files.FileFormat.getExtension | ( | ) |
Definition at line 445 of file FileFormat.java.
Referenced by denoptim.files.FileUtils.detectFileFormat(), denoptim.programs.fragmenter.FragmenterParameters.getMWSlotFileNameAllFrags(), and denoptim.programs.fragmenter.FragmenterParameters.getMWSlotFileNameUnqFrags().
Set< String > denoptim.files.FileFormat.getNegatingRegex | ( | ) |
Returns the list of regex strings that exclude a file format.
Definition at line 438 of file FileFormat.java.
|
static |
Returns the collection of file formats with input parameters.
Definition at line 362 of file FileFormat.java.
References denoptim.files.FileFormat.B3D_PARAM, denoptim.files.FileFormat.CLG_PARAM, denoptim.files.FileFormat.COMP_MAP, denoptim.files.FileFormat.FR_PARAM, denoptim.files.FileFormat.FRG_PARAM, denoptim.files.FileFormat.FSE_PARAM, denoptim.files.FileFormat.GA_PARAM, denoptim.files.FileFormat.GE_PARAM, denoptim.files.FileFormat.GI_PARAM, and denoptim.files.FileFormat.GO_PARAM.
Referenced by denoptim.files.FileUtils.detectKindOfParameterFile().
String denoptim.files.FileFormat.getSampleEndRegex | ( | ) |
In identifying a text file we read as many lines as possible until we match the "end-of-sample" string.
This method returns the regex that defines the "end-of-sample" string.
Definition at line 416 of file FileFormat.java.
|
static |
Returns the collection of file formats using SDF syntax.
Definition at line 345 of file FileFormat.java.
References denoptim.files.FileFormat.CANDIDATESDF, denoptim.files.FileFormat.GRAPHSDF, denoptim.files.FileFormat.MOLSDF, and denoptim.files.FileFormat.VRTXSDF.
Referenced by denoptim.files.FileUtils.detectKindOfSDFFile().
|
static |
Returns the collection of file formats restricted to TXT files (excluded parameter files)
Definition at line 387 of file FileFormat.java.
References denoptim.files.FileFormat.CUTRULE, denoptim.files.FileFormat.GENSUMMARY, and denoptim.files.FileFormat.GRAPHTXT.
Referenced by denoptim.files.FileUtils.detectKindOfTXTFile().
boolean denoptim.files.FileFormat.isFolder | ( | ) |
true
if the file is supposed to be a folder Definition at line 403 of file FileFormat.java.
denoptim.files.FileFormat.B3D_PARAM |
Definition at line 39 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getParameterFormats().
denoptim.files.FileFormat.CANDIDATESDF |
Definition at line 34 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getSDFFormats(), denoptim.io.DenoptimIO.writeCandidatesToFile(), and denoptim.io.DenoptimIO.writeCandidateToFile().
denoptim.files.FileFormat.CLG_PARAM |
Definition at line 38 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getParameterFormats().
denoptim.files.FileFormat.COMP_MAP |
Definition at line 38 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getParameterFormats(), denoptim.gui.GUICompatibilityMatrixTab.initialize(), denoptim.gui.MainToolBar.initialize(), and denoptim.io.DenoptimIOTest.testDetectFileFormat().
denoptim.files.FileFormat.CUTRULE |
Definition at line 39 of file FileFormat.java.
Referenced by denoptim.gui.CuttingRulesSelectionDialog.CuttingRulesSelectionDialog(), denoptim.files.FileFormat.getTXTFormats(), and denoptim.gui.GUIFileSaver.pickFileForSavingCuttingRules().
|
private |
Collection of regex that, if matched, suggests assigning the format to a specific FileFormat.
Consider a logical OR operator, i.e., any match will suggest among the set of regex will lead to format interpretation. Regex are matches against toUpperCase strings, so they behave as case-insensitive.
Definition at line 53 of file FileFormat.java.
|
private |
Regex used to identify the end of the sampled text used to determine the format of a file.
Regex are matches against toUpperCase strings, so they behave as case-insensitive.
Definition at line 67 of file FileFormat.java.
|
private |
Definition at line 44 of file FileFormat.java.
denoptim.files.FileFormat.FR_PARAM |
Definition at line 38 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getParameterFormats(), and denoptim.gui.MainToolBar.initialize().
denoptim.files.FileFormat.FRG_PARAM |
Definition at line 39 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getParameterFormats().
denoptim.files.FileFormat.FRG_RUN |
Definition at line 39 of file FileFormat.java.
Referenced by denoptim.programs.fragmenter.FragmenterParameters.createWorkingDirectory().
denoptim.files.FileFormat.FSE_PARAM |
Definition at line 38 of file FileFormat.java.
Referenced by denoptim.gui.GUIPrepare.getFileFormat(), denoptim.files.FileFormat.getParameterFormats(), denoptim.gui.MainToolBar.initialize(), and denoptim.io.DenoptimIOTest.testDetectFileFormat().
denoptim.files.FileFormat.FSE_RUN |
Definition at line 36 of file FileFormat.java.
Referenced by denoptim.programs.combinatorial.CEBLParameters.createWorkingDirectory(), denoptim.files.FileUtils.detectFileFormat(), denoptim.gui.MainToolBar.initialize(), and denoptim.io.DenoptimIOTest.testDetectFileFormat().
denoptim.files.FileFormat.GA_PARAM |
Definition at line 38 of file FileFormat.java.
Referenced by denoptim.gui.GUIPrepare.getFileFormat(), denoptim.files.FileFormat.getParameterFormats(), denoptim.gui.MainToolBar.initialize(), and denoptim.io.DenoptimIOTest.testDetectFileFormat().
denoptim.files.FileFormat.GA_RUN |
Definition at line 36 of file FileFormat.java.
Referenced by denoptim.programs.denovo.GAParameters.createWorkingDirectory(), denoptim.files.FileUtils.detectFileFormat(), denoptim.gui.GUIPrepare.getFileFormat(), denoptim.gui.MainToolBar.initialize(), and denoptim.io.DenoptimIOTest.testDetectFileFormat().
denoptim.files.FileFormat.GE_PARAM |
Definition at line 38 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getParameterFormats().
denoptim.files.FileFormat.GENSUMMARY |
Definition at line 41 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getTXTFormats(), and denoptim.io.DenoptimIOTest.testDetectFileFormat().
denoptim.files.FileFormat.GI_PARAM |
Definition at line 39 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getParameterFormats().
denoptim.files.FileFormat.GO_PARAM |
Definition at line 38 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getParameterFormats().
denoptim.files.FileFormat.GRAPHJSON |
Definition at line 35 of file FileFormat.java.
Referenced by denoptim.files.FileUtils.detectKindOfJSONFile(), and denoptim.programs.grapheditor.GraphEdParameters.interpretKeyword().
denoptim.files.FileFormat.GRAPHSDF |
denoptim.files.FileFormat.GRAPHTXT |
Definition at line 41 of file FileFormat.java.
Referenced by denoptim.files.FileFormat.getTXTFormats().
|
private |
Definition at line 69 of file FileFormat.java.
denoptim.files.FileFormat.MOLSDF |
Definition at line 35 of file FileFormat.java.
Referenced by denoptim.fragmenter.ParallelFragmentationAlgorithm.doPostFlightOperations(), and denoptim.files.FileFormat.getSDFFormats().
|
private |
Collection of regex that, if matched, prevents assigning the format to a specific FileFormat.
Regex are matches against toUpperCase strings, so they behave as case-insensitive.
Definition at line 60 of file FileFormat.java.
denoptim.files.FileFormat.TXT |
Definition at line 41 of file FileFormat.java.
Referenced by denoptim.task.ProgramTask.printErrorToFile().
denoptim.files.FileFormat.UNRECOGNIZED |
Definition at line 42 of file FileFormat.java.
Referenced by denoptim.main.Main.ensureFileExistsAndIsReadable(), denoptim.io.DenoptimIO.readDENOPTIMData(), and denoptim.gui.GUI.run().
denoptim.files.FileFormat.VRTXJSON |
Definition at line 35 of file FileFormat.java.
Referenced by denoptim.files.FileUtils.detectKindOfJSONFile(), denoptim.io.DenoptimIOTest.testAppendToJSON(), denoptim.io.DenoptimIOTest.testIOEmptyVertex(), denoptim.io.DenoptimIOTest.testIOMolFragment(), and denoptim.io.DenoptimIOTest.testIOTemplate().
denoptim.files.FileFormat.VRTXSDF |
Definition at line 35 of file FileFormat.java.
Referenced by denoptim.fragmenter.ConformerExtractorTask.call(), denoptim.fragmenter.FragmenterTools.fragmentation(), denoptim.files.FileFormat.getSDFFormats(), denoptim.fragmenter.FragmenterTools.manageFragmentCollection(), denoptim.io.DenoptimIO.readDENOPTIMGraphsFromFile(), denoptim.fragmenter.FragmentClustererTest.testCluster(), denoptim.io.DenoptimIOTest.testDetectFileFormat(), denoptim.io.DenoptimIOTest.testIOEmptyVertex(), denoptim.io.DenoptimIOTest.testIOMolFragment(), and denoptim.io.DenoptimIOTest.testIOTemplate().