-
Notifications
You must be signed in to change notification settings - Fork 612
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ISPN-6056 Improve ReplicableCommand marshalling
- Loading branch information
Showing
90 changed files
with
1,609 additions
and
791 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
104 changes: 104 additions & 0 deletions
104
commons/src/main/java/org/infinispan/commons/marshall/AbstractDelegatingObjectOutput.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
package org.infinispan.commons.marshall; | ||
|
||
import java.io.IOException; | ||
import java.io.ObjectOutput; | ||
|
||
/** | ||
* // TODO: Document this | ||
* | ||
* @author Pedro Ruivo | ||
* @since 8.0 | ||
*/ | ||
public abstract class AbstractDelegatingObjectOutput implements ObjectOutput { | ||
|
||
protected final ObjectOutput objectOutput; | ||
|
||
protected AbstractDelegatingObjectOutput(ObjectOutput objectOutput) { | ||
this.objectOutput = objectOutput; | ||
} | ||
|
||
@Override | ||
public void writeObject(Object obj) throws IOException { | ||
objectOutput.writeObject(obj); | ||
} | ||
|
||
@Override | ||
public void write(int b) throws IOException { | ||
objectOutput.write(b); | ||
} | ||
|
||
@Override | ||
public void write(byte[] b) throws IOException { | ||
objectOutput.write(b); | ||
} | ||
|
||
@Override | ||
public void write(byte[] b, int off, int len) throws IOException { | ||
objectOutput.write(b, off, len); | ||
} | ||
|
||
@Override | ||
public void flush() throws IOException { | ||
objectOutput.flush(); | ||
} | ||
|
||
@Override | ||
public void close() throws IOException { | ||
objectOutput.close(); | ||
} | ||
|
||
@Override | ||
public void writeBoolean(boolean v) throws IOException { | ||
objectOutput.writeBoolean(v); | ||
} | ||
|
||
@Override | ||
public void writeByte(int v) throws IOException { | ||
objectOutput.writeByte(v); | ||
} | ||
|
||
@Override | ||
public void writeShort(int v) throws IOException { | ||
objectOutput.writeShort(v); | ||
} | ||
|
||
@Override | ||
public void writeChar(int v) throws IOException { | ||
objectOutput.writeChar(v); | ||
} | ||
|
||
@Override | ||
public void writeInt(int v) throws IOException { | ||
objectOutput.writeInt(v); | ||
} | ||
|
||
@Override | ||
public void writeLong(long v) throws IOException { | ||
objectOutput.writeLong(v); | ||
} | ||
|
||
@Override | ||
public void writeFloat(float v) throws IOException { | ||
objectOutput.writeFloat(v); | ||
} | ||
|
||
@Override | ||
public void writeDouble(double v) throws IOException { | ||
objectOutput.writeDouble(v); | ||
} | ||
|
||
@Override | ||
public void writeBytes(String s) throws IOException { | ||
objectOutput.writeBytes(s); | ||
} | ||
|
||
@Override | ||
public void writeChars(String s) throws IOException { | ||
objectOutput.writeChars(s); | ||
} | ||
|
||
@Override | ||
public void writeUTF(String s) throws IOException { | ||
objectOutput.writeUTF(s); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.