philadelphia-core: Clean up 'FIXConnection'
Move methods that are only used in 'MessageHandler' to that class.
@@ -659,22 +659,6 @@ public class FIXConnection implements Closeable {
statusListener.logon(FIXConnection.this, message);
}
- private void msgSeqNumNotFound() throws IOException {
- sendLogout("MsgSeqNum(34) not found");
- }
-
- private void msgTypeNotFound() throws IOException {
- statusListener.close(FIXConnection.this, "MsgType(35) not found");
- }
-
- }
-
- private void sendHeartbeat() throws IOException {
- prepare(txMessage, Heartbeat);
-
- send(txMessage);
- }
-
private void sendHeartbeat(FIXValue testReqId) throws IOException {
prepare(txMessage, Heartbeat);
@@ -683,14 +667,6 @@ public class FIXConnection implements Closeable {
send(txMessage);
}
- private void sendTestRequest(CharSequence testReqId) throws IOException {
- prepare(txMessage, TestRequest);
-
- txMessage.addField(TestReqID).setString(testReqId);
-
- send(txMessage);
- }
-
private void sendResendRequest(long beginSeqNo) throws IOException {
prepare(txMessage, ResendRequest);
@@ -710,6 +686,30 @@ public class FIXConnection implements Closeable {
send(txMessage);
}
+ private void msgSeqNumNotFound() throws IOException {
+ sendLogout("MsgSeqNum(34) not found");
+ }
+
+ private void msgTypeNotFound() throws IOException {
+ statusListener.close(FIXConnection.this, "MsgType(35) not found");
+ }
+
+ }
+
+ private void sendHeartbeat() throws IOException {
+ prepare(txMessage, Heartbeat);
+
+ send(txMessage);
+ }
+
+ private void sendTestRequest(CharSequence testReqId) throws IOException {
+ prepare(txMessage, TestRequest);
+
+ txMessage.addField(TestReqID).setString(testReqId);
+
+ send(txMessage);
+ }
+
private static void tooLongMessage() throws FIXMessageOverflowException {
throw new FIXMessageOverflowException("Too long message");
}
