com.perforce.p4java.impl.mapbased.rpc.sys
Class RpcLineEndFilterOutputStream

java.lang.Object
  extended by java.io.OutputStream
      extended by java.io.FilterOutputStream
          extended by com.perforce.p4java.impl.mapbased.rpc.sys.RpcLineEndFilterOutputStream
All Implemented Interfaces:
Closeable, Flushable

public class RpcLineEndFilterOutputStream
extends FilterOutputStream

Simple FilterOutputStream extension to deal with Perforce text file line end translation.


Field Summary
static byte P4SERVER_LINSEP_BYTE
           
static String P4SERVER_LINSEP_STR
          What the Perforce server uses as a line end separator when sending us text file contents
 
Fields inherited from class java.io.FilterOutputStream
out
 
Constructor Summary
RpcLineEndFilterOutputStream(OutputStream out, ClientLineEnding lineEnding)
           
 
Method Summary
 void write(byte[] bytes)
           
 void write(byte[] bytes, int off, int len)
           
 void write(OutputStream out, byte[] bytes, int off, int len)
           
 
Methods inherited from class java.io.FilterOutputStream
close, flush, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

P4SERVER_LINSEP_STR

public static final String P4SERVER_LINSEP_STR
What the Perforce server uses as a line end separator when sending us text file contents

See Also:
Constant Field Values

P4SERVER_LINSEP_BYTE

public static final byte P4SERVER_LINSEP_BYTE
See Also:
Constant Field Values
Constructor Detail

RpcLineEndFilterOutputStream

public RpcLineEndFilterOutputStream(OutputStream out,
                                    ClientLineEnding lineEnding)
Method Detail

write

public void write(OutputStream out,
                  byte[] bytes,
                  int off,
                  int len)
           throws IOException
Throws:
IOException

write

public void write(byte[] bytes,
                  int off,
                  int len)
           throws IOException
Overrides:
write in class FilterOutputStream
Throws:
IOException

write

public void write(byte[] bytes)
           throws IOException
Overrides:
write in class FilterOutputStream
Throws:
IOException


Copyright © 2015 Perforce Software. All Rights Reserved.