Package com.dna.jopt.io.importing
Interface IOptimizationImporter
- All Superinterfaces:
IJOptImporter<IOptimization>
- All Known Implementing Classes:
OptimizationJSONImporter
The Interface IOptimizationImporter.
- Since:
- Sep 26, 2019
- Version:
- Sep 26, 2019
- Author:
- Jens Richter
-
Method Summary
Modifier and TypeMethodDescriptionread(InputStream fis) Read.booleanupdate(InputStream fis, IOptimization existingOpti) Takes an existingIOptimizationinstance and updates it with an optimization from an InputStream.booleanupdate(InputStream fis, IOptimization existingOpti, boolean isIgnoreExistingSolution) Takes an existingIOptimizationinstance and updates it with an optimization from an InputStream.booleanupdate(InputStream fis, IOptimization existingOpti, Optional<INodeEdgeConnector> existingNodeConnector, Properties existingProperties, boolean isOnlyPropertyUpdate) Takes an existingIOptimizationinstance and updates it with an optimization from an InputStream.booleanupdate(InputStream fis, IOptimization existingOpti, Optional<INodeEdgeConnector> existingNodeConnector, Properties existingProperties, boolean isOnlyPropertyUpdate, boolean isIgnoreExistingSolution) Takes an existingIOptimizationinstance and updates it with an optimization from an InputStream.
-
Method Details
-
read
Read.- Specified by:
readin interfaceIJOptImporter<IOptimization>- Parameters:
fis- the fis- Returns:
- the optional
-
update
Takes an existingIOptimizationinstance and updates it with an optimization from an InputStream.- Parameters:
fis- the InputStreamexistingOpti- the existing optimization- Returns:
- true, if successful
-
update
Takes an existingIOptimizationinstance and updates it with an optimization from an InputStream. If isIgnoreExistingSolution is true, the existing solution of the snapshot will be ignored.- Parameters:
fis- the fisexistingOpti- the existing optiisIgnoreExistingSolution- the is ignore existing solution- Returns:
- true, if successful
-
update
boolean update(InputStream fis, IOptimization existingOpti, Optional<INodeEdgeConnector> existingNodeConnector, Properties existingProperties, boolean isOnlyPropertyUpdate) Takes an existingIOptimizationinstance and updates it with an optimization from an InputStream. Further, anINodeEdgeConnectorcan be provided to replace it with the one from the InputStream. Additional, properties must be provided. IfisOnlyPropertyUpdate==truethe provided properties are used to update the properties from the InputStream. IfisOnlyPropertyUpdate==falsethe provided properties are used to replace the property settings from the InputStream.- Parameters:
fis- the InputStreamexistingOpti- the existing optimizationexistingNodeConnector- an existing node connectorexistingProperties- the existing propertiesisOnlyPropertyUpdate- the is only property update- Returns:
- true, if successful
-
update
boolean update(InputStream fis, IOptimization existingOpti, Optional<INodeEdgeConnector> existingNodeConnector, Properties existingProperties, boolean isOnlyPropertyUpdate, boolean isIgnoreExistingSolution) Takes an existingIOptimizationinstance and updates it with an optimization from an InputStream. Further, anINodeEdgeConnectorcan be provided to replace it with the one from the InputStream. Additional, properties must be provided. IfisOnlyPropertyUpdate==truethe provided properties are used to update the properties from the InputStream. IfisOnlyPropertyUpdate==falsethe provided properties are used to replace the property settings from the InputStream. If isIgnoreExistingSolution is true, the existing solution of the snapshot will be ignored.- Parameters:
fis- the fisexistingOpti- the existing optiexistingNodeConnector- the existing node connectorexistingProperties- the existing propertiesisOnlyPropertyUpdate- the is only property updateisIgnoreExistingSolution- the is ignore existing solution- Returns:
- true, if successful
-