本文整理汇总了C#中QuickFix.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# QuickFix.ToString方法的具体用法?C# QuickFix.ToString怎么用?C# QuickFix.ToString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类QuickFix
的用法示例。
在下文中一共展示了QuickFix.ToString方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: c
public static OrderAction c(QuickFix.Fields.Side s)
{
var val = s_sides.Find(v => v.first.getValue() == s.getValue());
if (val == null)
throw new Exception("Unmapped QuickFix.Fields.Side value : " + s.ToString());
return val.second;
}
示例2: FromApp
public void FromApp(QuickFix.Message msg, SessionID sessionID)
{
Console.WriteLine("FromApp - " + msg.ToString() + "@" + sessionID.ToString());
try
{
Crack(msg, sessionID);
}
catch (Exception ex)
{
Console.WriteLine("==Cracker exception==");
Console.WriteLine(ex.ToString());
Console.WriteLine(ex.StackTrace);
}
}
示例3: ToApp
public void ToApp(QuickFix.Message message, QuickFix.SessionID sessionId)
{
_strategy.ProcessToApp(message, QuickFix.Session.LookupSession(sessionId));
Trace.WriteLine("## ToApp: " + message.ToString());
if (MessageEvent != null)
MessageEvent(message, false);
}
示例4: OnCreate
public void OnCreate(QuickFix.SessionID sessionID)
{
Trace.WriteLine("## OnCreate: " + sessionID.ToString());
}
示例5: fromApp
/// <summary>
/// ���ԶԶ˵�Ӧ�ò㱨�ģ���Ҫҵ��������
/// </summary>
/// <param name="pMessage"></param>
/// <param name="pSessionID"></param>
public void fromApp(QuickFix.Message pMessage, QuickFix.SessionID pSessionID)
{
string msgtype = pMessage.getHeader ().getString (35);
if (msgtype.StartsWith("Ans"))
{
//Console.WriteLine(pMessage.ToString());
switch (msgtype)
{
case "Ans003":
//string ccy=pMessage .getField (
case "Ans002":
if (OnError != null)
{
OnError(pMessage.ToString(), EventArgs.Empty);
}
break;
}
}
else
{
base.crack(pMessage, pSessionID);//����Ĭ�ϴ����������
}
pMessage.Dispose();//�����ֳ�����Ҫ
}
示例6: SendTheMessage
private void SendTheMessage(QuickFix.Message msg)
{
msg.Header.SetField(new QuickFix.Fields.TargetCompID(sessionID.SenderCompID));
msg.Header.SetField(new QuickFix.Fields.SenderCompID(sessionID.TargetCompID));
msg.Header.SetField(new QuickFix.Fields.MsgSeqNum(seqNum++));
session.Next(msg.ToString());
}
示例7: SendLogon
private void SendLogon(QuickFix.Message msg)
{
msg.Header.SetField(new QuickFix.Fields.TargetCompID(sessionID.SenderCompID));
msg.Header.SetField(new QuickFix.Fields.SenderCompID(sessionID.TargetCompID));
msg.Header.SetField(new QuickFix.Fields.MsgSeqNum(seqNum++));
msg.Header.SetField(new QuickFix.Fields.SendingTime(System.DateTime.UtcNow));
msg.SetField(new QuickFix.Fields.HeartBtInt(1));
session.Next(msg.ToString());
}
示例8: ToApp
public void ToApp(QuickFix.Message msg, SessionID sessionID)
{
Console.WriteLine("ToApp - " + msg.ToString() + "@" + sessionID.ToString());
}
示例9: MessageRecord
public MessageRecord(QuickFix.Message msg, bool isIncoming)
{
MsgText = msg.ToString().Replace(QuickFix.Message.SOH, "|");
Direction = isIncoming ? "IN" : "OUT";
Timestamp = msg.Header.GetDateTime(QuickFix.Fields.Tags.SendingTime);
}
示例10: CreateSyntheticOrder
/// <summary>
/// Create a synthetic order
/// </summary>
/// <param name="myMsg"></param>
/// <returns>n order</returns>
public KaiTrade.Interfaces.Order CreateSyntheticOrder(QuickFix.Message myFixMsg)
{
KaiTrade.Interfaces.Order myOrder = null;
try
{
if (m_Log.IsInfoEnabled)
{
m_Log.Info("exec report recd:" + myFixMsg.ToString());
}
// Get order manager
KaiTrade.Interfaces.OrderManager myOM = KTAFacade.Instance().Factory.GetOrderManager();
// these fields must be present
QuickFix.OrderID myOrderID = new QuickFix.OrderID();
myFixMsg.getField(myOrderID);
QuickFix.ExecType myExecType = new QuickFix.ExecType();
myFixMsg.getField(myExecType);
QuickFix.ExecID myExecID = new QuickFix.ExecID();
myFixMsg.getField(myExecID);
QuickFix.OrdStatus myOrdStatus = new QuickFix.OrdStatus();
myFixMsg.getField(myOrdStatus);
// Create the order
myOrder = myOM.CreateOrder();
// we need the clordid to update an existing order - if
// it is not present or unknow we create a synthetic order
QuickFix.ClOrdID myClOrdID = new QuickFix.ClOrdID();
if (myFixMsg.isSetField(myClOrdID))
{
myOrder.ClOrdID = myClOrdID;
}
}
catch (Exception myE)
{
m_Log.Error("CreateSyntheticOrder", myE);
}
return myOrder;
}
示例11: onMessage
public void onMessage(QuickFix.FIX43.Reject message, SessionID session)
{
this.provider.EmitError(string.Format(BeAEwTZGlZaeOmY5cm.J00weU3cM6(676), (object)message.ToString()));
}
示例12: FromApp
public void FromApp(QuickFix.Message msg, QuickFix.SessionID sessionID)
{
m_logger.Info(sessionID.SenderCompID, " FromApp msg : " + msg.ToString());
Crack(msg, sessionID);
}
示例13: ToAdmin
public void ToAdmin(QuickFix.Message msg, QuickFix.SessionID sessionID)
{
m_logger.Info(sessionID.SenderCompID," ToAdmin msg : " + msg.ToString());
//Crack(msg, sessionID);
}
示例14: FromAdmin
public void FromAdmin(QuickFix.Message message, QuickFix.SessionID sessionID)
{
if (message.Header.GetString(35) == QuickFix.FIX42.Reject.MsgType)
Console.WriteLine("REJECT RECEIVED: " + message.ToString());
Trace.WriteLine("## FromAdmin: " + message.ToString());
if (MessageEvent != null)
MessageEvent(message, true);
}
示例15: FromApp
public void FromApp(QuickFix.Message message, QuickFix.SessionID sessionID)
{
Trace.WriteLine("## FromApp: " + message.ToString());
if (MessageEvent != null)
MessageEvent(message, true);
Crack(message, sessionID);
}