public class MasterStreams extends MockConnection
MockConnection.MBusTestInputStream, MockConnection.MBusTestOutputStream
Connection.State
log
DEFAULT_BAUDRATE, is, os
Constructor and Description |
---|
MasterStreams(int bitPerSecond,
int responseTimeoutOffset) |
Modifier and Type | Method and Description |
---|---|
String |
getJsonFieldName() |
String |
getName() |
protected void |
lastByteReading(long endWaitTime) |
protected void |
lastByteWriting() |
void |
sendRequestAndCollectResponse(String request,
String response)
Send a request and wait for response
|
void |
sendRequestNoAnswer(String request,
int waittime) |
void |
sendRequestNoAnswer(String request,
int waittime,
int times) |
protected void |
setNextData(boolean removeFirst) |
checkNoDataLeft, close, getMockIs, getMockOs, open, replay
createFromJSON, fromJSON, getBitPerSecond, getConnState, getInputStream, getLoggingStream, getOutputStrteam, getResponseTimeOutOffset, setBitPerSecond, setConnState, setLoggingStream, setResponseTimeOutOffset, toJSON
protected void lastByteReading(long endWaitTime) throws IOException
lastByteReading
in class MockConnection
IOException
protected void lastByteWriting() throws IOException
lastByteWriting
in class MockConnection
IOException
public void sendRequestAndCollectResponse(String request, String response)
request
- response
- public void sendRequestNoAnswer(String request, int waittime, int times)
public void sendRequestNoAnswer(String request, int waittime)
protected void setNextData(boolean removeFirst)
setNextData
in class MockConnection
public String getJsonFieldName()
getJsonFieldName
in class Connection
public String getName()
getName
in class Connection
Copyright © 2009–2016 MBus4J. All rights reserved.