Skip to content

Commit 6693834

Browse files
author
cogmission
committed
Use different FSTObjectInput constructor which passes in the FSTConfiguration
1 parent 0b3630f commit 6693834

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

src/main/java/org/numenta/nupic/serialize/HTMObjectInput.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,12 @@
44
import java.io.InputStream;
55

66
import org.numenta.nupic.Persistable;
7+
import org.nustaq.serialization.FSTConfiguration;
78
import org.nustaq.serialization.FSTObjectInput;
89

910
public class HTMObjectInput extends FSTObjectInput {
10-
public HTMObjectInput(InputStream in) throws IOException {
11-
super(in);
11+
public HTMObjectInput(InputStream in, FSTConfiguration config) throws IOException {
12+
super(in, config);
1213
}
1314

1415
@SuppressWarnings("rawtypes")

src/main/java/org/numenta/nupic/serialize/HTMObjectOutput.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,12 @@
44
import java.io.OutputStream;
55

66
import org.numenta.nupic.Persistable;
7+
import org.nustaq.serialization.FSTConfiguration;
78
import org.nustaq.serialization.FSTObjectOutput;
89

910
public class HTMObjectOutput extends FSTObjectOutput {
10-
public HTMObjectOutput(OutputStream out) {
11-
super(out);
11+
public HTMObjectOutput(OutputStream out, FSTConfiguration config) {
12+
super(out, config);
1213
}
1314

1415
@SuppressWarnings("rawtypes")

src/main/java/org/numenta/nupic/serialize/SerializerCore.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundE
104104
* @throws IOException
105105
*/
106106
public HTMObjectInput getObjectInput(InputStream is) throws IOException {
107-
return new HTMObjectInput(is);
107+
return new HTMObjectInput(is, fastSerialConfig);
108108
}
109109

110110
/**
@@ -113,7 +113,7 @@ public HTMObjectInput getObjectInput(InputStream is) throws IOException {
113113
* @return the HTMObjectOutput
114114
*/
115115
public <T extends Persistable> HTMObjectOutput getObjectOutput(OutputStream os) {
116-
return new HTMObjectOutput(os);
116+
return new HTMObjectOutput(os, fastSerialConfig);
117117
}
118118

119119
/**

0 commit comments

Comments
 (0)