[PATCH 6/6] [mamda] Removed duplicate file


Ian Bell <IBell@...>
 

 




Please consider the environment before printing this e-mail.

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient or have received this e-mail in error, please advise the sender immediately by reply e-mail and delete this message and any attachments without retaining a copy.

Any unauthorised copying, disclosure or distribution of the material in this e-mail is strictly forbidden.


Ian Bell <IBell@...>
 

From 05b6a05828d2743d1eb2136ecf569f31563d2dfd Mon Sep 17 00:00:00 2001

Message-Id: <05b6a05828d2743d1eb2136ecf569f31563d2dfd.1348824474.git.ibell@...>

In-Reply-To: <766019e29e6ff6072c662caa2de6adbd3e9df875.1348824474.git.ibell@...>

References: <766019e29e6ff6072c662caa2de6adbd3e9df875.1348824474.git.ibell@...>

From: Ian Bell <ibell@...>

Date: Fri, 28 Sep 2012 10:27:00 +0100

Subject: [PATCH 6/6] [mamda] Removed duplicate file

 

Tradeselftest is a testtool not an example

 

Signed-off-by: Ian Bell <ibell@...>

---

mamda/c_cpp/src/examples/tradeselftest.cpp |  156 ----------------------------

1 file changed, 156 deletions(-)

 

diff --git a/mamda/c_cpp/src/examples/tradeselftest.cpp b/mamda/c_cpp/src/examples/tradeselftest.cpp

deleted file mode 100644

index 95d70b1..0000000

--- a/mamda/c_cpp/src/examples/tradeselftest.cpp

+++ /dev/null

@@ -1,156 +0,0 @@

-/* $Id$

- *

- * OpenMAMA: The open middleware agnostic messaging API

- * Copyright (C) 2011 NYSE Technologies, Inc.

- *

- * This library is free software; you can redistribute it and/or

- * modify it under the terms of the GNU Lesser General Public

- * License as published by the Free Software Foundation; either

- * version 2.1 of the License, or (at your option) any later version.

- *

- * This library is distributed in the hope that it will be useful,

- * but WITHOUT ANY WARRANTY; without even the implied warranty of

- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU

- * Lesser General Public License for more details.

- *

- * You should have received a copy of the GNU Lesser General Public

- * License along with this library; if not, write to the Free Software

- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA

- * 02110-1301 USA

- */

-

-#include <mamda/MamdaErrorListener.h>

-#include <mamda/MamdaTradeChecker.h>

-#include <mamda/MamdaTradeFields.h>

-#include <mamda/MamdaCommonFields.h>

-#include <mama/MamaSource.h>

-#include <iostream>

-#include <vector>

-#include <stdexcept>

-#include "parsecmd.h"

-#include "dictrequester.h"

-#include <mama/mamacpp.h>

-#include "mama/MamaQueueGroup.h"

-

-using std::exception;

-using std::endl;

-using std::vector;

-using std::cerr;

-using std::cout;

-

-using namespace Wombat;

-

-void usage (int exitStatus);

-

-class TradeSelfTest : public MamdaCheckerHandler

-{

-public:

-    TradeSelfTest () {}

-    virtual ~TradeSelfTest() {}

-

-    void onSuccess (MamdaCheckerType type)

-    {

-        if (gExampleLogLevel == EXAMPLE_LOG_LEVEL_NORMAL)

-        {

-            cout << "Successful check ("

-                 << mamdaCheckTypeToString(type) << ")\n";

-        }

-    }

-

-    void onInconclusive (MamdaCheckerType  type,

-                         const char*       reason)

-    {

-        if (gExampleLogLevel == EXAMPLE_LOG_LEVEL_NORMAL)

-        {

-            cout << "Inconclusive check ("

-                 << mamdaCheckTypeToString(type) << "): "

-                 << " " << reason << "\n";

-        }

-    }

-

-    void onFailure (MamdaCheckerType  type,

-                    const char*       reason,

-                    const MamaMsg&    msg)

-    {

-        cout << "Failed check ("

-             << mamdaCheckTypeToString(type) << "): "

-             << reason << "\n";

-        if (gExampleLogLevel >= EXAMPLE_LOG_LEVEL_QUIET)

-        {

-            cout << "Failed message: " << msg.toString() << "\n";

-        }

-    }

-};

-

-

-int main (int argc, const char** argv)

-{

-    try

-    {

-        //Initialise the MAMA API

-        CommonCommandLineParser     cmdLine (argc, argv);

-        mamaBridge bridge = cmdLine.getBridge();

-        Mama::open ();

-        const vector<const char*>&

-                         symbolList        = cmdLine.getSymbolList ();

-        MamaSource*      source            = cmdLine.getSource();

-        MamaQueueGroup   queues (cmdLine.getNumThreads(),bridge);

-        DictRequester    dictRequester (bridge);

-        uint32_t         intervalSecs      = cmdLine.getOptInt('i');       

-

-        if (intervalSecs == 0)

-        {

-            intervalSecs = 5;

-        }

-       

-

-        // Get and initialize the dictionary

-        dictRequester.requestDictionary (cmdLine.getDictSource());

-        MamdaCommonFields::setDictionary (*dictRequester.getDictionary());

-        MamdaTradeFields::setDictionary (*dictRequester.getDictionary());

-       

-

-        for (vector<const char*>::const_iterator i = symbolList.begin();

-            i != symbolList.end();

-            ++i)

-        {

-            const char* symbol = *i;

-            TradeSelfTest* aSelfTest = new TradeSelfTest;

-            MamdaTradeChecker*  aTradechecker  =

-                new MamdaTradeChecker (queues.getNextQueue(), aSelfTest,

-                                           source, symbol, intervalSecs);

-        }

-        Mama::start(bridge);

-    }

-    catch (MamaStatus &e)

-    {

-

-        // This exception can be thrown from Mama.open ()

-        // Mama::createTransport (transportName) and from

-        // MamdaSubscription constructor when entitlements is enabled.

-        cerr << "MamaStatus exception in main (): " << e.toString () << endl;

-        exit (1);

-    }

-

-    catch (exception &ex)

-    {

-        cerr << "Exception in main (): " << ex.what () << endl;

-        exit (1);

-    }

-

-    catch (...)

-    {

-        cerr << "Unknown Exception in main ()." << endl;

-        exit (1);

-    }

-   

-

-    return 1;

-}

-

-void usage (int exitStatus)

-{

-    std::cerr << "Usage: tradeselftest [-tport] tport_name [-m] middleware [-S] source [-s] symbol\n";

-    exit(exitStatus);

-}

-

--

1.7.9.5

 

From: openmama-dev-bounces@... [mailto:openmama-dev-bounces@...] On Behalf Of Ian Bell
Sent: 28 September 2012 10:35
To: openmama-dev@...
Subject: [Openmama-dev] [PATCH 6/6] [mamda] Removed duplicate file

 

 

 



Please consider the environment before printing this e-mail.

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient or have received this e-mail in error, please advise the sender immediately by reply e-mail and delete this message and any attachments without retaining a copy.

Any unauthorised copying, disclosure or distribution of the material in this e-mail is strictly forbidden.




Please consider the environment before printing this e-mail.

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient or have received this e-mail in error, please advise the sender immediately by reply e-mail and delete this message and any attachments without retaining a copy.

Any unauthorised copying, disclosure or distribution of the material in this e-mail is strictly forbidden.