RE: [Quickfix-developers] User Defined Message Types....
Brought to you by:
orenmnero
From: <OM...@th...> - 2003-02-11 18:57:10
|
Your constructor name for SPEXOrderMassCancelReport is incorrect. You are trying to name the constructor SPEXOrderMassCancelRequest. See the code excerpt from your file below: //======================================================= class SPEXOrderMassCancel**Report** : public FIX42::Message { //======================================================= public: SPEXOrderMassCancel**Request**() : Message( MsgType() ) {} SPEXOrderMassCancel**Request**( const Message& m ) : Message( m ) {} --oren "Austin" <austin@iontradin To: <OM...@th...> g.com> cc: Subject: RE: [Quickfix-developers] User Defined Message Types.... 02/11/2003 12:34 PM Please respond to austin Okay, here are the two files. The problem occurs in a file that includes both of the attachment files... Thanks again Regards, Austin -----Original Message----- From: OM...@th... [mailto:OM...@th...] Sent: 11 February 2003 18:30 To: au...@io... Subject: RE: [Quickfix-developers] User Defined Message Types.... Looks like the error's start outside of the code that you included in your original message. If you can send your spexmessages.h file as an attachment, that will help. --oren "Austin" <austin@iontradin To: <OM...@th...> g.com> cc: Subject: RE: [Quickfix-developers] User Defined Message Types.... 02/11/2003 12:15 PM Please respond to austin I'm using the MS VC++6.0 on windows... Here is the message I got, thanks. (The file MyApplication.cpp uses the SpexMessages.h file...) Compiling... MyApplication.cpp m:\include\mkv12x\quickfix\spexmessages.h(26) : error C2664: '__thiscall FIX42::Message::FIX42::Message(const class FIX::MsgType &)' : cannot convert parameter 1 from 'const class FIX::Message' to 'const class FIX::MsgType &' Reason: cannot convert from 'const class FIX::Message' to 'const class FIX::MsgType' No constructor could take the source type, or constructor overload resolution was ambiguous m:\include\mkv12x\quickfix\spexmessages.h(279) : error C2057: expected constant expression m:\include\mkv12x\quickfix\spexmessages.h(279) : error C2656: 'SPEXOrderMassCancelRequest' : function not allowed as a bit field m:\include\mkv12x\quickfix\spexmessages.h(279) : warning C4183: 'SPEXOrderMassCancelRequest': member function definition looks like a ctor, but name does not match enclosing class m:\include\mkv12x\quickfix\spexmessages.h(280) : error C2327: 'SPEXOrderMassCancelReport::SPEXOrderMassCancelRequest' : member from enclosing class is not a type name, static, or enumerator m:\include\mkv12x\quickfix\spexmessages.h(280) : error C2065: 'm' : undeclared identifier m:\include\mkv12x\quickfix\spexmessages.h(280) : error C2440: 'type cast' : cannot convert from 'int' to 'class FIX42::Message' No constructor could take the source type, or constructor overload resolution was ambiguous m:\include\mkv12x\quickfix\spexmessages.h(280) : error C2056: illegal expression m:\include\mkv12x\quickfix\spexmessages.h(280) : error C2656: 'SPEXOrderMassCancelRequest' : function not allowed as a bit field m:\include\mkv12x\quickfix\spexmessages.h(280) : warning C4183: 'SPEXOrderMassCancelRequest': member function definition looks like a ctor, but name does not match enclosing class c: \myfiles\fixproject\myfixapplication\myfixapplication\myfixapplication\mya pplication.h(34) : error C2039: 'SPEXOrderSingle' : is not a member of 'FIX42' c: \myfiles\fixproject\myfixapplication\myfixapplication\myfixapplication\mya pplication.h(34) : error C2143: syntax error : missing ',' before '&' c: \myfiles\fixproject\myfixapplication\myfixapplication\myfixapplication\mya pplication.h(34) : error C2059: syntax error : '&' -----Original Message----- From: qui...@li... [mailto:qui...@li...]On Behalf Of OM...@th... Sent: 11 February 2003 18:04 To: au...@io... Cc: qui...@li...; qui...@li... Subject: Re: [Quickfix-developers] User Defined Message Types.... Please identify which compiler you are using and provide the error output being produced. --oren |---------+-----------------------------------------------> | | "Austin" <au...@io...> | | | Sent by: | | | qui...@li...ur| | | ceforge.net | | | | | | | | | 02/11/2003 11:44 AM | | | Please respond to austin | | | | |---------+-----------------------------------------------> > --------------------------------------------------------------------------- -------------------| | | | To: <qui...@li...> | | cc: | | Subject: [Quickfix-developers] User Defined Message Types.... | > --------------------------------------------------------------------------- -------------------| Can you please help, I have defined my own type as below but the two standard constructors are causing compilation error... Many thanks constructors... SPEXOrderSingle() : Message( MsgType() ) {} SPEXOrderSingle( const Message& m ) : Message( m ) {} Actual code..... . . . namespace FIX { const char MsgType_SPEXOrderSingle[] = "D"; const char MsgType_SPEXExecutionReport[] = "8"; const char MsgType_SPEXOrderCancelReplaceRequest[] = "G"; const char MsgType_SPEXOrderCancelRequest[] = "F"; const char MsgType_SPEXOrderMassCancelRequest[] = "q"; const char MsgType_SPEXOrderMassCancelReport[] = "r"; //=============================================== class SPEXOrderSingle : public FIX42::Message { //=============================================== public: SPEXOrderSingle() : Message( MsgType() ) {} SPEXOrderSingle( const Message& m ) : Message( m ) {} static FIX::MsgType MsgType() { return FIX::MsgType( "D" ); } SPEXOrderSingle( const FIX::ClOrdID& aClOrdID, const FIX::ClOrdLinkID& aClOrdLinkID, const FIX::UUID& aUUID, const FIX::HandlInst& aHandlInst, const FIX::OrderQty& aOrderQty, const FIX::Side& aSide, const FIX::TransactTime& aTransactTime, const FIX::OrdType& aOrdType ) : Message( FIX::MsgType( "D" ) ) { set( aClOrdID ); set( aClOrdLinkID ); set( aUUID ); set( aHandlInst ); set( aOrderQty ); set( aSide ); set( aTransactTime ); set( aOrdType ); } FIELD_SET( *this, FIX::ClOrdID ); FIELD_SET( *this, FIX::ClOrdLinkID ); FIELD_SET( *this, FIX::UUID ); FIELD_SET( *this, FIX::ClientID ); FIELD_SET( *this, FIX::Account ); FIELD_SET( *this, FIX::SettlmntTyp ); FIELD_SET( *this, FIX::FutSettDate ); FIELD_SET( *this, FIX::HandlInst ); FIELD_SET( *this, FIX::SecurityID ); FIELD_SET( *this, FIX::IDSource ); FIELD_SET( *this, FIX::Side ); FIELD_SET( *this, FIX::LocateReqd ); FIELD_SET( *this, FIX::TransactTime ); FIELD_SET( *this, FIX::OrderQty ); FIELD_SET( *this, FIX::OrdType ); FIELD_SET( *this, FIX::Price ); FIELD_SET( *this, FIX::ExpireTime ); FIELD_SET( *this, FIX::TradingSessionID ); FIELD_SET( *this, FIX::BenchmarkCurveName ); FIELD_SET( *this, FIX::SpexMaturity ); FIELD_SET( *this, FIX::PriceType ); FIELD_SET( *this, FIX::ExecID ); FIELD_SET( *this, FIX::SettlLocation ); FIELD_SET( *this, FIX::AccountType ); FIELD_SET( *this, FIX::PreallocMethod ); FIELD_SET( *this, FIX::PartyId ); FIELD_SET( *this, FIX::UnderlyingSecurityID ); FIELD_SET( *this, FIX::UnderlyingIDSource ); FIELD_SET( *this, FIX::SpreadToBenchmark ); }; } ------------------------------------------------------- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com _______________________________________________ Quickfix-developers mailing list Qui...@li... https://lists.sourceforge.net/lists/listinfo/quickfix-developers ------------------------------------------------------- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com _______________________________________________ Quickfix-developers mailing list Qui...@li... https://lists.sourceforge.net/lists/listinfo/quickfix-developers (See attached file: SpexFields.h)(See attached file: SpexMessages.h) |