public void Next(string msgStr)
{
try
{
this.Log.OnIncoming(msgStr);
MsgType msgType = Message.IdentifyType(msgStr);
string beginString = Message.ExtractBeginString(msgStr);
Message message = msgFactory_.Create(beginString, msgType.Obj);
message.FromString(
msgStr,
this.ValidateLengthAndChecksum,
this.SessionDataDictionary,
this.ApplicationDataDictionary);
Next(message);
}
catch (InvalidMessage e)
{
this.Log.OnEvent(e.Message);
try
{
if (MsgType.LOGON.Equals(Message.IdentifyType(msgStr)))
{
Disconnect("Logon message is not valid");
}
}
catch (MessageParseError)
{ }
throw e;
}
}