Skip to content

Commit dad51b3

Browse files
committed
WIP #982 Matlab file read/write for double and boolean matrices
Use library: - https://github.com/HebiRobotics/MFL
1 parent 7ab6199 commit dad51b3

File tree

1 file changed

+5
-1
lines changed
  • symja_android_library/matheclipse-core/src/main/java/org/matheclipse/core/reflection/system

1 file changed

+5
-1
lines changed

symja_android_library/matheclipse-core/src/main/java/org/matheclipse/core/reflection/system/Export.java

+5-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package org.matheclipse.core.reflection.system;
22

33
import java.awt.image.BufferedImage;
4+
import java.io.FileNotFoundException;
45
import java.io.FileOutputStream;
56
import java.io.FileWriter;
67
import java.io.IOException;
@@ -119,12 +120,15 @@ public IExpr evaluate(final IAST ast, EvalEngine engine) {
119120
} else if (format.equals(Extension.DAT)) {
120121
Files.writeString(Path.of(filename), arg2.toString(), Charset.defaultCharset());
121122
return arg1;
123+
} else if (format.equals(Extension.MAT)) {
124+
//
122125
} else if (format.equals(Extension.WXF)) {
123126
byte[] bArray = WL.serialize(arg2);
124127
Files.write(Path.of(filename), bArray);
125128
return arg1;
126129
}
127-
130+
} catch (FileNotFoundException ex) {
131+
LOGGER.log(engine.getLogLevel(), "Export: file {}", arg1, ex);
128132
} catch (IOException ioe) {
129133
LOGGER.log(engine.getLogLevel(), "Export: file {} not found!", arg1, ioe);
130134
} catch (Exception ex) {

0 commit comments

Comments
 (0)