public void onUpdate(MamdaSecurityStatusListener listener, MamaMsgField field) { if (string.Compare(listener.mSecurityStatusCache.mSecStatusOrigStr, field.getString()) != 0) { listener.mSecurityStatusCache.mSecStatusOrigStr = field.getString(); listener.mSecurityStatusCache.mSecStatusOrigStrFieldState = MamdaFieldState.MODIFIED; listener.mUpdated = true; } }
public string getFieldAsString(MamaMsgField field) { switch (field.getType()) { case mamaFieldType.MAMA_FIELD_TYPE_I8: case mamaFieldType.MAMA_FIELD_TYPE_U8: case mamaFieldType.MAMA_FIELD_TYPE_I16: case mamaFieldType.MAMA_FIELD_TYPE_U16: case mamaFieldType.MAMA_FIELD_TYPE_I32: case mamaFieldType.MAMA_FIELD_TYPE_U32: return(field.getU32().ToString()); case mamaFieldType.MAMA_FIELD_TYPE_STRING: return(field.getString()); default: break; } return(null); }
public void onUpdate( MamdaTradeListener listener, MamaMsgField field) { listener.mTradeCache.mLastPartId = field.getString(); listener.mTradeCache.mLastPartIdFieldState = MamdaFieldState.MODIFIED; listener.mTradeCache.mGotPartId = true; listener.mTradeCache.mIsIrregular = false; }
public void onUpdate( MamdaTradeListener listener, MamaMsgField field) { listener.mTradeCache.mIrregPartId = field.getString(); listener.mTradeCache.mIrregPartIdFieldState = MamdaFieldState.MODIFIED; if (listener.mTradeCache.mIrregPartId != "" && listener.mTradeCache.mIsIrregular == false) { listener.mTradeCache.mIsIrregular = true; listener.mTradeCache.mIsIrregularFieldState = MamdaFieldState.MODIFIED; } }
public void onUpdate(MamdaOrderImbalanceListener listener, MamaMsgField field) { switch (field.getType()) { case mamaFieldType.MAMA_FIELD_TYPE_CHAR : listener.mOrderImbalanceCache.mNoClearingPrice = field.getChar (); listener.mOrderImbalanceCache.mNoClearingPriceFieldState = MamdaFieldState.MODIFIED; break; case mamaFieldType.MAMA_FIELD_TYPE_STRING : if (field.getString() != String.Empty) { listener.mOrderImbalanceCache.mNoClearingPrice = field.getString()[0]; listener.mOrderImbalanceCache.mNoClearingPriceFieldState = MamdaFieldState.MODIFIED; } else { listener.mOrderImbalanceCache.mNoClearingPrice = ' '; listener.mOrderImbalanceCache.mNoClearingPriceFieldState = MamdaFieldState.MODIFIED; } break; default : break; } }
public void onUpdate( MamdaTradeListener listener, MamaMsgField field) { listener.mTradeCache.mIssueSymbol = field.getString(); listener.mTradeCache.mIssueSymbolFieldState = MamdaFieldState.MODIFIED; listener.mTradeCache.mGotIssueSymbol = true; }
public void onUpdate(MamdaAuctionListener listener, MamaMsgField field) { listener.mAuctionCache.mSymbol = field.getString(); listener.mAuctionCache.mSymbolFieldState = MamdaFieldState.MODIFIED; }
public void onUpdate(MamdaOrderImbalanceListener listener, MamaMsgField field) { listener.mOrderImbalanceCache.mSecurityStatusQual = field.getString (); listener.mOrderImbalanceCache.mSecurityStatusQualFieldState = MamdaFieldState.MODIFIED; }
public void onUpdate( MamdaTradeListener listener, MamaMsgField field) { listener.mTradeCache.mOrigPartId = field.getString(); listener.mTradeCache.mOrigPartIdFieldState = MamdaFieldState.MODIFIED; }
public void onUpdate( MamdaTradeListener listener, MamaMsgField field) { switch (field.getType()) { case mamaFieldType.MAMA_FIELD_TYPE_CHAR: listener.mTradeCache.mCorrStopStockInd = field.getChar(); listener.mTradeCache.mCorrStopStockIndFieldState = MamdaFieldState.MODIFIED; break; case mamaFieldType.MAMA_FIELD_TYPE_STRING: if (field.getString() != String.Empty) { listener.mTradeCache.mCorrStopStockInd = field.getString()[0]; listener.mTradeCache.mCorrStopStockIndFieldState = MamdaFieldState.MODIFIED; } else { listener.mTradeCache.mCorrStopStockInd = ' '; listener.mTradeCache.mCorrStopStockIndFieldState = MamdaFieldState.MODIFIED; } break; default: break; } }
public void onUpdate(MamdaAuctionListener listener, MamaMsgField field) { listener.mAuctionCache.mPartId = field.getString(); listener.mAuctionCache.mPartIdFieldState = MamdaFieldState.MODIFIED; }
public void onUpdate( MamdaTradeListener listener, MamaMsgField field) { switch (field.getType()) { case mamaFieldType.MAMA_FIELD_TYPE_I8: case mamaFieldType.MAMA_FIELD_TYPE_U8: case mamaFieldType.MAMA_FIELD_TYPE_I16: case mamaFieldType.MAMA_FIELD_TYPE_U16: case mamaFieldType.MAMA_FIELD_TYPE_I32: case mamaFieldType.MAMA_FIELD_TYPE_U32: listener.mTradeCache.mTradeExecVenue = field.getU32().ToString(); listener.mTradeCache.mTradeExecVenueFieldState = MamdaFieldState.MODIFIED; break; case mamaFieldType.MAMA_FIELD_TYPE_STRING: listener.mTradeCache.mTradeExecVenue = field.getString(); listener.mTradeCache.mTradeExecVenueFieldState = MamdaFieldState.MODIFIED; break; default: break; } }
public void onUpdate (MamdaQuoteListener listener, MamaMsgField field) { if (field.getType() == mamaFieldType.MAMA_FIELD_TYPE_STRING) { listener.mQuoteCache.mBidIndicator = field.getString(); listener.mQuoteCache.mBidIndicatorFieldState = MamdaFieldState.MODIFIED; } else if (field.getType() == mamaFieldType.MAMA_FIELD_TYPE_CHAR) { listener.mQuoteCache.mBidIndicator = field.getChar().ToString(); listener.mQuoteCache.mBidIndicatorFieldState = MamdaFieldState.MODIFIED; } }
public void onUpdate(MamdaQuoteListener listener, MamaMsgField field) { switch (field.getType()) { case mamaFieldType.MAMA_FIELD_TYPE_CHAR : listener.mQuoteCache.mShortSaleBidTick = field.getChar(); listener.mQuoteCache.mShortSaleBidTickFieldState = MamdaFieldState.MODIFIED; break; case mamaFieldType.MAMA_FIELD_TYPE_STRING : if (field.getString() != String.Empty) { listener.mQuoteCache.mShortSaleBidTick = field.getString()[0]; listener.mQuoteCache.mShortSaleBidTickFieldState = MamdaFieldState.MODIFIED; } else { listener.mQuoteCache.mShortSaleBidTick = ' '; listener.mQuoteCache.mShortSaleBidTickFieldState = MamdaFieldState.MODIFIED; } break; default : break; } }
public void onUpdate(MamdaQuoteListener listener, MamaMsgField field) { listener.mQuoteCache.mQuoteQualStr = field.getString(); listener.mQuoteCache.mQuoteQualStrFieldState = MamdaFieldState.MODIFIED; }
public void onUpdate(MamdaQuoteListener listener, MamaMsgField field) { string askPartId = field.getString(); if (listener.mQuoteCache.mAskPartId != askPartId) { listener.mQuoteCache.mAskPartId = askPartId; listener.mQuoteCache.mAskPartIdFieldState = MamdaFieldState.MODIFIED; listener.mQuoteCache.mGotAskPartId = true; } }
public void onUpdate(MamdaQuoteListener listener, MamaMsgField field) { listener.mQuoteCache.mPartId = field.getString(); listener.mQuoteCache.mPartIdFieldState = MamdaFieldState.MODIFIED; listener.mQuoteCache.mGotPartId = true; }
public void onUpdate( MamdaTradeListener listener, MamaMsgField field) { listener.mTradeCache.mCurrencyCode = field.getString(); listener.mTradeCache.mCurrencyCodeFieldState = MamdaFieldState.MODIFIED; }
public void onUpdate(MamdaSecurityStatusListener listener, MamaMsgField field) { if (string.Compare(listener.mSecurityStatusCache.mSecStatusOrigStr, field.getString()) != 0) { listener.mSecurityStatusCache.mSecStatusOrigStr = field.getString(); listener.mSecurityStatusCache.mSecStatusOrigStrFieldState = MamdaFieldState.MODIFIED; listener.mUpdated = true; } }
public void onUpdate( MamdaTradeListener listener, MamaMsgField field) { listener.mTradeCache.mCorrCondStr = field.getString(); listener.mTradeCache.mCorrCondStrFieldState = MamdaFieldState.MODIFIED; }
public void onUpdate(MamdaOrderImbalanceListener listener, MamaMsgField field) { listener.mOrderImbalanceCache.mPartId = field.getString (); listener.mOrderImbalanceCache.mPartIdFieldState = MamdaFieldState.MODIFIED; }
public string getFieldAsString(MamaMsgField field) { switch (field.getType()) { case mamaFieldType.MAMA_FIELD_TYPE_I8: case mamaFieldType.MAMA_FIELD_TYPE_U8: case mamaFieldType.MAMA_FIELD_TYPE_I16: case mamaFieldType.MAMA_FIELD_TYPE_U16: case mamaFieldType.MAMA_FIELD_TYPE_I32: case mamaFieldType.MAMA_FIELD_TYPE_U32: return field.getU32().ToString(); case mamaFieldType.MAMA_FIELD_TYPE_STRING: return field.getString(); default: break; } return null; }
/// <summary> /// Display the contents of a field in the console window. /// </summary> /// <param name="field"> /// The field to display. /// </param> /// <param name="indent"> /// The level of indent to add before the string for formatting purposes. /// </param> internal void displayField(MamaMsgField field, int indent) { // Format a log string string logMessage = ""; string indentSpacer = " "; for (int i = 0; i < indent; i++) indentSpacer += " "; if (m_quietness < 1) { logMessage = string.Format( "{0}{1, -20 } |{2,5} | {3, 10} | ", indentSpacer, field.getName(), field.getFid(), field.getTypeName()); } mamaFieldType fieldType = field.getType(); switch (fieldType) { case mamaFieldType.MAMA_FIELD_TYPE_MSG: { MamaMsg tmpMsg = field.getMsg(); Console.WriteLine(logMessage); Console.WriteLine(indentSpacer + "{"); if (!(m_iterator)) { tmpMsg.iterateFields(this, m_dictionary, indent + 1); } else { MamaMsgIterator subIterator = new MamaMsgIterator(m_dictionary); MamaMsgField subField; tmpMsg.begin(ref subIterator); while ((subField = subIterator.getField()) != null) { displayField(subField, indent + 1); subIterator++; } } Console.WriteLine(indentSpacer + "}"); } break; case mamaFieldType.MAMA_FIELD_TYPE_VECTOR_MSG: { MamaMsg[] tmpMsgarray = field.getVectorMsg(); foreach (MamaMsg tmpMsg in tmpMsgarray) { Console.WriteLine(logMessage); Console.WriteLine(indentSpacer + "{"); if (!(m_iterator)) { tmpMsg.iterateFields(this, m_dictionary, indent + 1); } else { MamaMsgIterator subIterator = new MamaMsgIterator(m_dictionary); MamaMsgField subField; tmpMsg.begin(ref subIterator); while ((subField = subIterator.getField()) != null) { displayField(subField, indent + 1); subIterator++; } } Console.WriteLine(indentSpacer + "}"); } } break; case mamaFieldType.MAMA_FIELD_TYPE_STRING: logMessage += field.getString(); break; case mamaFieldType.MAMA_FIELD_TYPE_BOOL: if (m_quietness < 1) logMessage += field.getBool().ToString(); else logMessage += field.getBool(); break; case mamaFieldType.MAMA_FIELD_TYPE_CHAR: if (m_quietness < 1) logMessage += field.getChar().ToString(); else logMessage += field.getChar(); break; case mamaFieldType.MAMA_FIELD_TYPE_I8: if (m_quietness < 1) logMessage += field.getI8().ToString(); else logMessage += field.getI8(); break; case mamaFieldType.MAMA_FIELD_TYPE_U8: if (m_quietness < 1) logMessage += field.getU8().ToString(); else logMessage += field.getU8(); break; case mamaFieldType.MAMA_FIELD_TYPE_I16: if (m_quietness < 1) logMessage += field.getI16().ToString(); else logMessage += field.getI16(); break; case mamaFieldType.MAMA_FIELD_TYPE_U16: if (m_quietness < 1) logMessage += field.getU16().ToString(); else logMessage += field.getU16(); break; case mamaFieldType.MAMA_FIELD_TYPE_I32: if (m_quietness < 1) logMessage += field.getI32().ToString(); else logMessage += field.getI32(); break; case mamaFieldType.MAMA_FIELD_TYPE_U32: if (m_quietness < 1) logMessage += field.getU32().ToString(); else logMessage += field.getU32(); break; case mamaFieldType.MAMA_FIELD_TYPE_I64: if (m_quietness < 1) logMessage += field.getI64().ToString(); else logMessage += field.getI64(); break; case mamaFieldType.MAMA_FIELD_TYPE_U64: if (m_quietness < 1) logMessage += field.getU64().ToString(); else logMessage += field.getU64(); break; case mamaFieldType.MAMA_FIELD_TYPE_F32: if (m_quietness < 1) logMessage += field.getF32().ToString(); else logMessage += field.getF32(); break; case mamaFieldType.MAMA_FIELD_TYPE_F64: if (m_quietness < 1) logMessage += field.getF64().ToString(); else logMessage += field.getF64(); break; case mamaFieldType.MAMA_FIELD_TYPE_TIME: if (m_quietness < 1) logMessage += field.getDateTime().ToString(); else logMessage += field.getDateTime(); break; case mamaFieldType.MAMA_FIELD_TYPE_PRICE: if (m_quietness < 1) logMessage += field.getPrice().getAsString(); else logMessage += field.getPrice(); break; default: logMessage += field.getAsString(); break; } Console.WriteLine(logMessage); }