01: package com.jeta.forms.store;
02:
03: import java.io.IOException;
04: import java.io.ObjectOutput;
05:
06: public class JavaExternalizableObjectOutput implements JETAObjectOutput {
07:
08: private ObjectOutput m_out;
09:
10: public JavaExternalizableObjectOutput(ObjectOutput delegate) {
11: m_out = delegate;
12: }
13:
14: public void writeVersion(int version) throws IOException {
15: m_out.writeInt(version);
16: }
17:
18: public void writeFloat(String tagName, float value)
19: throws IOException {
20: m_out.writeFloat(value);
21: }
22:
23: public void writeInt(String tagName, int value) throws IOException {
24: m_out.writeInt(value);
25: }
26:
27: public void writeObject(String tagName, Object obj)
28: throws IOException {
29: m_out.writeObject(obj);
30: }
31:
32: public void writeBoolean(String string, boolean boolValue)
33: throws IOException {
34: m_out.writeBoolean(boolValue);
35: }
36:
37: public JETAObjectOutput getSuperClassOutput(Class super Class) {
38: return this ;
39: }
40:
41: public void writeInt(String string, int value, int defaultValue)
42: throws IOException {
43: m_out.writeInt(value);
44:
45: }
46:
47: public void writeFloat(String string, float value,
48: float defaultValue) throws IOException {
49: m_out.writeFloat(value);
50: }
51:
52: public void writeBoolean(String string, boolean bval,
53: boolean defaultValue) throws IOException {
54: m_out.writeBoolean(bval);
55: }
56: }
|