org.apache.mina.transport.serial
Interface SerialSessionConfig

All Superinterfaces:
IoSessionConfig

public interface SerialSessionConfig
extends IoSessionConfig

An IoSessionConfig for serial transport type. All those parameters are extracted from rxtx.org API for more details : http://www.rxtx.org

Version:
$Rev: 529576 $, $Date: 2007-04-17 14:25:07 +0200 (mar., 17 avr. 2007) $
Author:
The Apache MINA Project (dev@mina.apache.org)

Method Summary
 int getInputBufferSize()
          Gets the input buffer size.
 int getReceiveThreshold()
          The current receive threshold (-1 if not enabled).
 boolean isLowLatency()
          Is the low latency mode is enabled.
 void setInputBufferSize(int bufferSize)
          Sets the input buffer size.
 void setLowLatency(boolean lowLatency)
          Set the low latency mode, be carefull it's not supported by all the OS/hardware.
 void setReceiveThreshold(int bytes)
          Set the receive threshold in byte (set it to -1 for disable).
 
Methods inherited from interface org.apache.mina.core.session.IoSessionConfig
getBothIdleTime, getBothIdleTimeInMillis, getIdleTime, getIdleTimeInMillis, getMaxReadBufferSize, getMinReadBufferSize, getReadBufferSize, getReaderIdleTime, getReaderIdleTimeInMillis, getThroughputCalculationInterval, getThroughputCalculationIntervalInMillis, getWriterIdleTime, getWriterIdleTimeInMillis, getWriteTimeout, getWriteTimeoutInMillis, isUseReadOperation, setAll, setBothIdleTime, setIdleTime, setMaxReadBufferSize, setMinReadBufferSize, setReadBufferSize, setReaderIdleTime, setThroughputCalculationInterval, setUseReadOperation, setWriterIdleTime, setWriteTimeout
 

Method Detail

getInputBufferSize

int getInputBufferSize()
Gets the input buffer size. Note that this method is advisory and the underlying OS may choose not to report correct values for the buffer size.

Returns:
input buffer size in bytes

setInputBufferSize

void setInputBufferSize(int bufferSize)
Sets the input buffer size. Note that this is advisory and memory availability may determine the ultimate buffer size used by the driver.

Parameters:
bufferSize - the buffer size in bytes

isLowLatency

boolean isLowLatency()
Is the low latency mode is enabled.

Returns:
low latency on

setLowLatency

void setLowLatency(boolean lowLatency)
Set the low latency mode, be carefull it's not supported by all the OS/hardware.

Parameters:
lowLatency -

getReceiveThreshold

int getReceiveThreshold()
The current receive threshold (-1 if not enabled). Give the value of the current buffer needed for generate a new frame.

Returns:
the receive thresold in bytes or -1 if disabled

setReceiveThreshold

void setReceiveThreshold(int bytes)
Set the receive threshold in byte (set it to -1 for disable). The serial port will try to provide frame of the given minimal byte count. Be carefull some devices doesn't support it.

Parameters:
bytes - minimal amount of byte before producing a new frame, or -1 if disabled


Copyright © 2004-2008 Apache MINA Project. All Rights Reserved.