mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Reorganize source file hierarchy:
* Rename unity files * Move some modules to new subdirectories * Remove obsolete Visual Studio project files * Remove obsolete coding style and TODO list
This commit is contained in:
152
src/ripple/unity/app.cpp
Normal file
152
src/ripple/unity/app.cpp
Normal file
@@ -0,0 +1,152 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/bimap.hpp>
|
||||
#include <boost/bimap/list_of.hpp>
|
||||
#include <boost/bimap/multiset_of.hpp>
|
||||
#include <boost/bimap/unordered_set_of.hpp>
|
||||
#include <boost/optional.hpp>
|
||||
#include <boost/version.hpp>
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/unity/net.h>
|
||||
#include <ripple/unity/rpcx.h>
|
||||
#include <ripple/unity/websocket.h>
|
||||
#include <ripple/common/jsonrpc_fields.h>
|
||||
|
||||
// This .cpp will end up including all of the public header
|
||||
// material in Ripple since it holds the Application object.
|
||||
|
||||
#include <ripple/common/seconds_clock.h>
|
||||
#include <ripple/unity/http.h>
|
||||
#include <ripple/unity/resource.h>
|
||||
#include <ripple/unity/sitefiles.h>
|
||||
#include <ripple/unity/validators.h>
|
||||
|
||||
#include <beast/asio/io_latency_probe.h>
|
||||
#include <beast/cxx14/memory.h>
|
||||
|
||||
#include <fstream> // For Application.cpp
|
||||
|
||||
#include <ripple/module/app/main/CollectorManager.h>
|
||||
#include <ripple/module/app/main/CollectorManager.cpp>
|
||||
|
||||
#include <ripple/module/app/misc/ProofOfWorkFactory.h>
|
||||
|
||||
#include <ripple/module/app/main/NodeStoreScheduler.h>
|
||||
#include <ripple/module/app/main/NodeStoreScheduler.cpp>
|
||||
|
||||
#include <ripple/module/app/main/IoServicePool.h>
|
||||
#include <ripple/module/app/main/IoServicePool.cpp>
|
||||
|
||||
#include <ripple/module/app/main/FatalErrorReporter.h>
|
||||
#include <ripple/module/app/main/FatalErrorReporter.cpp>
|
||||
|
||||
#include <ripple/module/app/rpc/RPCHandler.h>
|
||||
#include <ripple/module/app/rpc/RPCServerHandler.h>
|
||||
#include <ripple/module/app/main/RPCHTTPServer.h>
|
||||
#include <ripple/module/app/main/RPCHTTPServer.cpp>
|
||||
#include <ripple/module/app/rpc/RPCServerHandler.cpp>
|
||||
#include <ripple/module/app/rpc/RPCHandler.cpp>
|
||||
|
||||
#include <ripple/module/app/websocket/WSConnection.h>
|
||||
|
||||
#include <ripple/module/app/tx/TxQueueEntry.h>
|
||||
#include <ripple/module/app/tx/TxQueueEntry.cpp>
|
||||
#include <ripple/module/app/tx/TxQueue.h>
|
||||
#include <ripple/module/app/tx/TxQueue.cpp>
|
||||
|
||||
#include <ripple/module/app/websocket/WSServerHandler.h>
|
||||
#include <ripple/module/app/websocket/WSServerHandler.cpp>
|
||||
#include <ripple/module/app/websocket/WSConnection.cpp>
|
||||
#include <ripple/module/app/websocket/WSDoor.h>
|
||||
#include <ripple/module/app/websocket/WSDoor.cpp>
|
||||
|
||||
#include <ripple/common/ResolverAsio.h>
|
||||
|
||||
#include <ripple/module/app/node/SqliteFactory.h>
|
||||
#include <ripple/module/app/node/SqliteFactory.cpp>
|
||||
|
||||
#include <ripple/module/app/main/Application.cpp>
|
||||
|
||||
#include <ripple/module/app/main/Main.cpp>
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace ripple {
|
||||
int run (int argc, char** argv);
|
||||
}
|
||||
|
||||
struct ProtobufLibrary
|
||||
{
|
||||
~ProtobufLibrary ()
|
||||
{
|
||||
google::protobuf::ShutdownProtobufLibrary();
|
||||
}
|
||||
};
|
||||
|
||||
// Must be outside the namespace for obvious reasons
|
||||
//
|
||||
int main (int argc, char** argv)
|
||||
{
|
||||
#if defined(__GNUC__) && !defined(__clang__)
|
||||
auto constexpr gccver = (__GNUC__ * 100 * 100) +
|
||||
(__GNUC_MINOR__ * 100) +
|
||||
__GNUC_PATCHLEVEL__;
|
||||
|
||||
static_assert (gccver >= 40801,
|
||||
"GCC version 4.8.1 or later is required to compile rippled.");
|
||||
#endif
|
||||
|
||||
#ifdef _MSC_VER
|
||||
static_assert (_MSC_VER >= 1800,
|
||||
"Visual Studio 2013 or later is required to compile rippled.");
|
||||
#endif
|
||||
|
||||
static_assert (BOOST_VERSION >= 105500,
|
||||
"Boost version 1.55 or later is required to compile rippled");
|
||||
|
||||
//
|
||||
// These debug heap calls do nothing in release or non Visual Studio builds.
|
||||
//
|
||||
|
||||
// Checks the heap at every allocation and deallocation (slow).
|
||||
//
|
||||
//beast::Debug::setAlwaysCheckHeap (false);
|
||||
|
||||
// Keeps freed memory blocks and fills them with a guard value.
|
||||
//
|
||||
//beast::Debug::setHeapDelayedFree (false);
|
||||
|
||||
// At exit, reports all memory blocks which have not been freed.
|
||||
//
|
||||
#if RIPPLE_DUMP_LEAKS_ON_EXIT
|
||||
beast::Debug::setHeapReportLeaks (true);
|
||||
#else
|
||||
beast::Debug::setHeapReportLeaks (false);
|
||||
#endif
|
||||
|
||||
beast::SharedSingleton <ProtobufLibrary>::get ();
|
||||
|
||||
return ripple::run (argc, argv);
|
||||
}
|
||||
135
src/ripple/unity/app.h
Normal file
135
src/ripple/unity/app.h
Normal file
@@ -0,0 +1,135 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_APP_H_INCLUDED
|
||||
#define RIPPLE_APP_H_INCLUDED
|
||||
|
||||
#if BEAST_LINUX || BEAST_MAC || BEAST_BSD
|
||||
#include <sys/resource.h>
|
||||
#endif
|
||||
|
||||
// VFALCO TODO Reduce these boost dependencies. Make more interfaces
|
||||
// purely abstract and move implementation into .cpp files.
|
||||
//
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/algorithm/string/predicate.hpp>
|
||||
#include <boost/array.hpp>
|
||||
#include <boost/asio/read_until.hpp>
|
||||
#include <boost/asio/streambuf.hpp>
|
||||
#include <boost/iostreams/stream.hpp>
|
||||
#include <boost/mem_fn.hpp>
|
||||
#include <boost/pointer_cast.hpp>
|
||||
#include <boost/program_options.hpp>
|
||||
#include <boost/tuple/tuple.hpp>
|
||||
#include <boost/tuple/tuple_comparison.hpp>
|
||||
#include <boost/unordered_set.hpp>
|
||||
#include <boost/weak_ptr.hpp>
|
||||
#include <boost/thread/shared_mutex.hpp>
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
#include <ripple/unity/basics.h>
|
||||
#include <ripple/unity/core.h>
|
||||
#include <ripple/unity/data.h>
|
||||
#include <ripple/unity/net.h>
|
||||
|
||||
#include <ripple/common/ResolverAsio.h>
|
||||
|
||||
// VFALCO TODO Remove this include
|
||||
#include <beast/module/sqlite/sqlite.h>
|
||||
|
||||
// Order matters here. If you get compile errors,
|
||||
// reorder the include lines until the order is correct.
|
||||
|
||||
#include <ripple/common/KeyCache.h>
|
||||
#include <ripple/common/TaggedCache.h>
|
||||
|
||||
#include <ripple/module/app/data/Database.h>
|
||||
#include <ripple/module/app/data/DatabaseCon.h>
|
||||
#include <ripple/module/app/data/SqliteDatabase.h>
|
||||
#include <ripple/module/app/data/DBInit.h>
|
||||
#include <ripple/module/app/shamap/SHAMapItem.h>
|
||||
#include <ripple/module/app/shamap/SHAMapNode.h>
|
||||
#include <ripple/module/app/shamap/SHAMapTreeNode.h>
|
||||
#include <ripple/module/app/shamap/SHAMapMissingNode.h>
|
||||
#include <ripple/module/app/shamap/SHAMapSyncFilter.h>
|
||||
#include <ripple/module/app/shamap/SHAMapAddNode.h>
|
||||
#include <ripple/module/app/shamap/SHAMap.h>
|
||||
#include <ripple/module/app/misc/SerializedTransaction.h>
|
||||
#include <ripple/module/app/misc/SerializedLedger.h>
|
||||
#include <ripple/module/app/tx/TransactionMeta.h>
|
||||
#include <ripple/module/app/tx/Transaction.h>
|
||||
#include <ripple/module/app/misc/AccountState.h>
|
||||
#include <ripple/module/app/misc/NicknameState.h>
|
||||
#include <ripple/module/app/ledger/Ledger.h>
|
||||
#include <ripple/module/app/ledger/SerializedValidation.h>
|
||||
#include <ripple/module/app/main/LoadManager.h>
|
||||
#include <ripple/module/app/misc/OrderBook.h>
|
||||
#include <ripple/module/app/shamap/SHAMapSyncFilters.h>
|
||||
#include <ripple/module/app/misc/AmendmentTable.h>
|
||||
#include <ripple/module/app/misc/FeeVote.h>
|
||||
#include <ripple/module/app/misc/IHashRouter.h>
|
||||
#include <ripple/module/app/peers/ClusterNodeStatus.h>
|
||||
#include <ripple/module/app/peers/UniqueNodeList.h>
|
||||
#include <ripple/module/app/misc/Validations.h>
|
||||
#include <ripple/module/app/peers/PeerSet.h>
|
||||
#include <ripple/module/app/ledger/InboundLedger.h>
|
||||
#include <ripple/module/app/ledger/InboundLedgers.h>
|
||||
#include <ripple/module/app/misc/AccountItem.h>
|
||||
#include <ripple/module/app/misc/AccountItems.h>
|
||||
#include <ripple/module/app/ledger/AcceptedLedgerTx.h>
|
||||
#include <ripple/module/app/ledger/AcceptedLedger.h>
|
||||
#include <ripple/module/app/ledger/LedgerEntrySet.h>
|
||||
#include <ripple/module/app/ledger/DirectoryEntryIterator.h>
|
||||
#include <ripple/module/app/ledger/OrderBookIterator.h>
|
||||
#include <ripple/module/app/tx/TransactionEngine.h>
|
||||
#include <ripple/module/app/misc/CanonicalTXSet.h>
|
||||
#include <ripple/module/app/ledger/LedgerHolder.h>
|
||||
#include <ripple/module/app/ledger/LedgerHistory.h>
|
||||
#include <ripple/module/app/ledger/LedgerCleaner.h>
|
||||
#include <ripple/module/app/ledger/LedgerMaster.h>
|
||||
#include <ripple/module/app/ledger/LedgerProposal.h>
|
||||
#include <ripple/module/app/misc/NetworkOPs.h>
|
||||
#include <ripple/module/app/tx/TransactionMaster.h>
|
||||
#include <ripple/module/app/main/LocalCredentials.h>
|
||||
#include <ripple/module/app/main/Application.h>
|
||||
#include <ripple/module/app/ledger/OrderBookDB.h>
|
||||
#include <ripple/module/app/tx/TransactionAcquire.h>
|
||||
#include <ripple/module/app/tx/LocalTxs.h>
|
||||
#include <ripple/module/app/consensus/DisputedTx.h>
|
||||
#include <ripple/module/app/consensus/LedgerConsensus.h>
|
||||
#include <ripple/module/app/ledger/LedgerTiming.h>
|
||||
#include <ripple/module/app/misc/Offer.h>
|
||||
#include <ripple/module/app/paths/RippleLineCache.h>
|
||||
#include <ripple/module/app/paths/PathRequest.h>
|
||||
#include <ripple/module/app/paths/PathRequests.h>
|
||||
#include <ripple/module/app/main/ParameterTable.h>
|
||||
#include <ripple/module/app/paths/RippleLineCache.h>
|
||||
#include <ripple/module/app/paths/PathState.h>
|
||||
#include <ripple/module/app/paths/RippleCalc.h>
|
||||
#include <ripple/module/app/paths/Pathfinder.h>
|
||||
#include <ripple/module/app/paths/RippleState.h>
|
||||
// VFALCO NOTE These contracts files are bunk
|
||||
#include <ripple/module/app/contracts/ScriptData.h>
|
||||
#include <ripple/module/app/contracts/Contract.h>
|
||||
#include <ripple/module/app/contracts/Interpreter.h>
|
||||
#include <ripple/module/app/contracts/Operation.h>
|
||||
|
||||
#endif
|
||||
47
src/ripple/unity/app1.cpp
Normal file
47
src/ripple/unity/app1.cpp
Normal file
@@ -0,0 +1,47 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/bimap.hpp>
|
||||
#include <boost/bimap/multiset_of.hpp>
|
||||
#include <boost/bimap/unordered_set_of.hpp>
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/unity/validators.h>
|
||||
|
||||
#include <ripple/module/app/misc/PowResult.h>
|
||||
|
||||
#include <ripple/module/app/misc/ProofOfWorkFactory.h>
|
||||
|
||||
#include <ripple/module/app/peers/PeerSet.cpp>
|
||||
#include <ripple/module/app/misc/OrderBook.cpp>
|
||||
#include <ripple/module/app/misc/ProofOfWorkFactory.cpp>
|
||||
#include <ripple/module/app/misc/ProofOfWork.cpp>
|
||||
#include <ripple/module/app/misc/SerializedTransaction.cpp>
|
||||
|
||||
#include <ripple/module/app/shamap/SHAMapSyncFilters.cpp> // requires Application
|
||||
|
||||
#include <ripple/module/app/consensus/LedgerConsensus.cpp>
|
||||
|
||||
#include <ripple/module/app/ledger/LedgerCleaner.h>
|
||||
#include <ripple/module/app/ledger/LedgerCleaner.cpp>
|
||||
#include <ripple/module/app/ledger/LedgerMaster.cpp>
|
||||
45
src/ripple/unity/app2.cpp
Normal file
45
src/ripple/unity/app2.cpp
Normal file
@@ -0,0 +1,45 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/common/seconds_clock.h>
|
||||
|
||||
#include <ripple/module/app/shamap/SHAMap.cpp> // Uses theApp
|
||||
#include <ripple/module/app/shamap/SHAMapItem.cpp>
|
||||
#include <ripple/module/app/shamap/SHAMapSync.cpp>
|
||||
#include <ripple/module/app/shamap/SHAMapMissingNode.cpp>
|
||||
|
||||
#include <ripple/module/app/misc/AccountItem.cpp>
|
||||
#include <ripple/module/app/misc/CanonicalTXSet.cpp>
|
||||
#include <ripple/module/app/ledger/LedgerProposal.cpp>
|
||||
#include <ripple/module/app/main/LoadManager.cpp>
|
||||
#include <ripple/module/app/misc/NicknameState.cpp>
|
||||
#include <ripple/module/app/ledger/OrderBookDB.cpp>
|
||||
|
||||
#include <ripple/module/app/data/Database.cpp>
|
||||
#include <ripple/module/app/data/DatabaseCon.cpp>
|
||||
#include <ripple/module/app/data/SqliteDatabase.cpp>
|
||||
#include <ripple/module/app/data/DBInit.cpp>
|
||||
|
||||
#include <ripple/module/app/shamap/RadixMapTest.h>
|
||||
#include <ripple/module/app/shamap/RadixMapTest.cpp>
|
||||
#include <ripple/module/app/shamap/FetchPackTests.cpp>
|
||||
33
src/ripple/unity/app3.cpp
Normal file
33
src/ripple/unity/app3.cpp
Normal file
@@ -0,0 +1,33 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/module/app/ledger/Ledger.cpp>
|
||||
#include <ripple/module/app/shamap/SHAMapDelta.cpp>
|
||||
#include <ripple/module/app/shamap/SHAMapNode.cpp>
|
||||
#include <ripple/module/app/shamap/SHAMapTreeNode.cpp>
|
||||
#include <ripple/module/app/misc/AccountItems.cpp>
|
||||
#include <ripple/module/app/misc/AccountState.cpp>
|
||||
#include <ripple/module/app/contracts/Contract.cpp>
|
||||
#include <ripple/module/app/contracts/Operation.cpp>
|
||||
#include <ripple/module/app/contracts/ScriptData.cpp>
|
||||
#include <ripple/module/app/contracts/Interpreter.cpp>
|
||||
42
src/ripple/unity/app4.cpp
Normal file
42
src/ripple/unity/app4.cpp
Normal file
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/unity/net.h>
|
||||
|
||||
#include <ripple/common/seconds_clock.h>
|
||||
|
||||
#include <fstream> // for UniqueNodeList.cpp
|
||||
|
||||
#include <ripple/module/app/transactors/Transactor.h>
|
||||
|
||||
#include <ripple/module/app/paths/RippleState.cpp>
|
||||
#include <ripple/module/app/peers/UniqueNodeList.cpp>
|
||||
#include <ripple/module/app/ledger/InboundLedger.cpp>
|
||||
#include <ripple/module/app/tx/TransactionCheck.cpp>
|
||||
#include <ripple/module/app/tx/TransactionMaster.cpp>
|
||||
#include <ripple/module/app/tx/Transaction.cpp>
|
||||
#include <ripple/module/app/tx/TransactionEngine.cpp>
|
||||
#include <ripple/module/app/tx/TransactionMeta.cpp>
|
||||
|
||||
#include <ripple/module/app/book/tests/OfferStream.test.cpp>
|
||||
#include <ripple/module/app/book/tests/Quality.test.cpp>
|
||||
40
src/ripple/unity/app5.cpp
Normal file
40
src/ripple/unity/app5.cpp
Normal file
@@ -0,0 +1,40 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
#include <ripple/unity/net.h>
|
||||
#include <ripple/common/jsonrpc_fields.h>
|
||||
|
||||
#include <ripple/common/seconds_clock.h>
|
||||
#include <ripple/unity/peerfinder.h>
|
||||
#include <ripple/unity/resource.h>
|
||||
#include <ripple/unity/validators.h>
|
||||
#include <ripple/common/RippleSSLContext.h>
|
||||
|
||||
#include <deque>
|
||||
|
||||
#include <ripple/module/app/misc/ProofOfWork.h>
|
||||
|
||||
#include <ripple/module/app/ledger/LedgerTiming.cpp>
|
||||
#include <ripple/module/app/ledger/AcceptedLedgerTx.cpp>
|
||||
#include <ripple/module/app/main/LocalCredentials.cpp>
|
||||
#include <ripple/module/app/misc/Validations.cpp>
|
||||
#include <ripple/module/app/misc/FeeVoteImpl.cpp>
|
||||
34
src/ripple/unity/app6.cpp
Normal file
34
src/ripple/unity/app6.cpp
Normal file
@@ -0,0 +1,34 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/common/seconds_clock.h>
|
||||
|
||||
#include <ripple/module/app/ledger/LedgerEntrySet.cpp>
|
||||
#include <ripple/module/app/ledger/AcceptedLedger.cpp>
|
||||
#include <ripple/module/app/ledger/DirectoryEntryIterator.cpp>
|
||||
#include <ripple/module/app/ledger/OrderBookIterator.cpp>
|
||||
#include <ripple/module/app/consensus/DisputedTx.cpp>
|
||||
#include <ripple/module/app/misc/HashRouter.cpp>
|
||||
#include <ripple/module/app/misc/Offer.cpp>
|
||||
#include <ripple/module/app/paths/Pathfinder.cpp>
|
||||
#include <ripple/module/app/misc/AmendmentTableImpl.cpp>
|
||||
36
src/ripple/unity/app7.cpp
Normal file
36
src/ripple/unity/app7.cpp
Normal file
@@ -0,0 +1,36 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/unity/resource.h>
|
||||
|
||||
#include <ripple/common/seconds_clock.h>
|
||||
|
||||
#include <ripple/module/app/ledger/InboundLedgers.cpp>
|
||||
#include <ripple/module/app/ledger/LedgerHistory.cpp>
|
||||
#include <ripple/module/app/misc/SerializedLedger.cpp>
|
||||
#include <ripple/module/app/tx/TransactionAcquire.cpp>
|
||||
|
||||
#include <ripple/module/app/tx/TxQueueEntry.h>
|
||||
#include <ripple/module/app/tx/TxQueue.h>
|
||||
#include <ripple/module/app/tx/LocalTxs.cpp>
|
||||
#include <ripple/module/app/misc/NetworkOPs.cpp>
|
||||
42
src/ripple/unity/app8.cpp
Normal file
42
src/ripple/unity/app8.cpp
Normal file
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning (push)
|
||||
#pragma warning (disable: 4309) // truncation of constant value
|
||||
#endif
|
||||
|
||||
#include <ripple/module/rpc/api/ErrorCodes.h>
|
||||
|
||||
#include <ripple/module/app/paths/PathRequest.cpp>
|
||||
#include <ripple/module/app/paths/PathRequests.cpp>
|
||||
#include <ripple/module/app/paths/RippleCalc.cpp>
|
||||
#include <ripple/module/app/paths/PathState.cpp>
|
||||
|
||||
#include <ripple/module/app/main/ParameterTable.cpp>
|
||||
#include <ripple/module/app/paths/RippleLineCache.cpp>
|
||||
#include <ripple/module/app/ledger/SerializedValidation.cpp>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning (pop)
|
||||
#endif
|
||||
44
src/ripple/unity/app9.cpp
Normal file
44
src/ripple/unity/app9.cpp
Normal file
@@ -0,0 +1,44 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/module/app/book/impl/Taker.cpp>
|
||||
#include <ripple/module/app/book/impl/BookTip.cpp>
|
||||
#include <ripple/module/app/book/impl/OfferStream.cpp>
|
||||
#include <ripple/module/app/book/impl/Quality.cpp>
|
||||
|
||||
#include <ripple/module/app/transactors/Transactor.cpp>
|
||||
|
||||
#include <ripple/module/app/transactors/Change.cpp>
|
||||
#include <ripple/module/app/transactors/CancelOffer.cpp>
|
||||
#include <ripple/module/app/transactors/Payment.cpp>
|
||||
#include <ripple/module/app/transactors/SetRegularKey.cpp>
|
||||
#include <ripple/module/app/transactors/SetAccount.cpp>
|
||||
#include <ripple/module/app/transactors/AddWallet.cpp>
|
||||
#include <ripple/module/app/transactors/SetTrust.cpp>
|
||||
#include <ripple/module/app/transactors/CreateOffer.cpp>
|
||||
#include <ripple/module/app/transactors/CreateOfferDirect.cpp>
|
||||
#include <ripple/module/app/transactors/CreateOfferBridged.cpp>
|
||||
|
||||
#if RIPPLE_USE_OLD_CREATE_TRANSACTOR
|
||||
#include <ripple/module/app/transactors/CreateOfferLegacy.cpp>
|
||||
#endif
|
||||
60
src/ripple/unity/basics.cpp
Normal file
60
src/ripple/unity/basics.cpp
Normal file
@@ -0,0 +1,60 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/basics.h>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/asio.hpp> // For StringUtilities.cpp
|
||||
|
||||
#include <fstream> // for Log files
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
// For Sustain Linux variants
|
||||
//
|
||||
// VFALCO TODO Rewrite Sustain to use beast::Process
|
||||
#ifdef __linux__
|
||||
#include <sys/types.h>
|
||||
#include <sys/prctl.h>
|
||||
#include <sys/wait.h>
|
||||
#endif
|
||||
#ifdef __FreeBSD__
|
||||
#include <sys/types.h>
|
||||
#include <sys/wait.h>
|
||||
#endif
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
#include <ripple/module/basics/containers/RangeSet.cpp>
|
||||
#include <ripple/module/basics/system/CheckLibraryVersions.cpp>
|
||||
|
||||
#include <ripple/module/basics/log/Log.cpp>
|
||||
#include <ripple/module/basics/log/LogFile.cpp>
|
||||
#include <ripple/module/basics/log/LogPartition.cpp>
|
||||
#include <ripple/module/basics/log/LogSink.cpp>
|
||||
|
||||
#include <ripple/module/basics/utility/CountedObject.cpp>
|
||||
#include <ripple/module/basics/utility/IniFile.cpp>
|
||||
#include <ripple/module/basics/utility/StringUtilities.cpp>
|
||||
#include <ripple/module/basics/utility/Sustain.cpp>
|
||||
#include <ripple/module/basics/utility/ThreadName.cpp>
|
||||
#include <ripple/module/basics/utility/Time.cpp>
|
||||
#include <ripple/module/basics/utility/UptimeTimer.cpp>
|
||||
66
src/ripple/unity/basics.h
Normal file
66
src/ripple/unity/basics.h
Normal file
@@ -0,0 +1,66 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_BASICS_H_INCLUDED
|
||||
#define RIPPLE_BASICS_H_INCLUDED
|
||||
|
||||
#include <beast/Crypto.h>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <ripple/module/basics/system/BoostIncludes.h>
|
||||
|
||||
#include <beast/cxx14/memory.h>
|
||||
#include <beast/utility/Zero.h>
|
||||
|
||||
#include <atomic>
|
||||
|
||||
using beast::zero;
|
||||
using beast::Zero;
|
||||
|
||||
// VFALCO TODO Lets ditch this macro
|
||||
#ifndef RIPPLE_TRACK_MUTEXES
|
||||
# define RIPPLE_TRACK_MUTEXES 0
|
||||
#endif
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
#include <ripple/unity/types.h>
|
||||
|
||||
#include <ripple/module/basics/types/BasicTypes.h>
|
||||
|
||||
#include <ripple/module/basics/log/LogSeverity.h>
|
||||
#include <ripple/module/basics/log/LogFile.h>
|
||||
#include <ripple/module/basics/log/LogSink.h>
|
||||
#include <ripple/module/basics/log/LogPartition.h>
|
||||
#include <ripple/module/basics/log/Log.h>
|
||||
#include <ripple/module/basics/log/LoggedTimings.h>
|
||||
|
||||
#include <ripple/module/basics/utility/CountedObject.h>
|
||||
#include <ripple/module/basics/utility/IniFile.h>
|
||||
#include <ripple/module/basics/utility/PlatformMacros.h>
|
||||
#include <ripple/module/basics/utility/StringUtilities.h>
|
||||
#include <ripple/module/basics/utility/Sustain.h>
|
||||
#include <ripple/module/basics/utility/ThreadName.h>
|
||||
#include <ripple/module/basics/utility/Time.h>
|
||||
#include <ripple/module/basics/utility/UptimeTimer.h>
|
||||
|
||||
#include <ripple/module/basics/containers/RangeSet.h>
|
||||
#include <ripple/module/basics/containers/SyncUnorderedMap.h>
|
||||
|
||||
#endif
|
||||
52
src/ripple/unity/beast.cpp
Normal file
52
src/ripple/unity/beast.cpp
Normal file
@@ -0,0 +1,52 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#if ! BEAST_COMPILE_OBJECTIVE_CPP
|
||||
|
||||
/* This file includes all of the beast sources needed to link.
|
||||
By including them here, we avoid having to muck with the SConstruct
|
||||
Makefile, Project file, or whatever.
|
||||
*/
|
||||
|
||||
// MUST come first!
|
||||
#include <BeastConfig.h>
|
||||
|
||||
// Include this to get all the basic includes included, to prevent errors
|
||||
#include <beast/module/core/core.unity.cpp>
|
||||
#include <beast/module/asio/asio.unity.cpp>
|
||||
#include <beast/module/sqdb/sqdb.unity.cpp>
|
||||
|
||||
#include <beast/asio/Asio.unity.cpp>
|
||||
#include <beast/boost/Boost.unity.cpp>
|
||||
#include <beast/chrono/Chrono.unity.cpp>
|
||||
#include <beast/container/Container.unity.cpp>
|
||||
#include <beast/crypto/Crypto.unity.cpp>
|
||||
#include <beast/http/HTTP.unity.cpp>
|
||||
#include <beast/insight/Insight.unity.cpp>
|
||||
#include <beast/net/Net.unity.cpp>
|
||||
#include <beast/streams/streams.unity.cpp>
|
||||
#include <beast/strings/Strings.unity.cpp>
|
||||
#include <beast/threads/Threads.unity.cpp>
|
||||
#include <beast/utility/Utility.unity.cpp>
|
||||
|
||||
#include <beast/cxx14/cxx14.unity.cpp>
|
||||
|
||||
#include <beast/unit_test/define_print.cpp>
|
||||
|
||||
#endif
|
||||
33
src/ripple/unity/beastc.c
Normal file
33
src/ripple/unity/beastc.c
Normal file
@@ -0,0 +1,33 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
/* This file includes all of the C-language beast sources needed to link.
|
||||
By including them here, we avoid having to muck with the SConstruct
|
||||
Makefile, Project file, or whatever.
|
||||
|
||||
Note that these sources must be compiled using the C compiler.
|
||||
*/
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
#error "Whoops! This file must be compiled with a C compiler!"
|
||||
#endif
|
||||
|
||||
#include <beast/module/sqlite/sqlite.unity.c>
|
||||
27
src/ripple/unity/beastobjc.mm
Normal file
27
src/ripple/unity/beastobjc.mm
Normal file
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#if ! BEAST_COMPILE_OBJECTIVE_CPP
|
||||
#error Incorrect compilation setting!
|
||||
#endif
|
||||
|
||||
#undef BEAST_COMPILE_OBJECTIVE_CPP
|
||||
#define BEAST_COMPILE_OBJECTIVE_CPP 0
|
||||
|
||||
#include "beast.unity.cpp"
|
||||
26
src/ripple/unity/common.cpp
Normal file
26
src/ripple/unity/common.cpp
Normal file
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/common/impl/KeyCache.cpp>
|
||||
#include <ripple/common/impl/TaggedCache.cpp>
|
||||
#include <ripple/common/impl/ResolverAsio.cpp>
|
||||
#include <ripple/common/impl/MultiSocket.cpp>
|
||||
#include <ripple/common/impl/RippleSSLContext.cpp>
|
||||
43
src/ripple/unity/core.cpp
Normal file
43
src/ripple/unity/core.cpp
Normal file
@@ -0,0 +1,43 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/core.h>
|
||||
|
||||
#include <fstream>
|
||||
#include <map>
|
||||
#include <set>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/algorithm/string.hpp>
|
||||
#include <boost/foreach.hpp>
|
||||
|
||||
#include <ripple/module/core/nodestore/NodeStore.cpp>
|
||||
#include <beast/http/ParsedURL.h>
|
||||
#include <ripple/unity/net.h> // for HTTPClient
|
||||
|
||||
#include <ripple/module/core/functional/Config.cpp>
|
||||
#include <ripple/module/core/functional/LoadFeeTrackImp.h> // private
|
||||
#include <ripple/module/core/functional/LoadFeeTrackImp.cpp>
|
||||
#include <ripple/module/core/functional/LoadEvent.cpp>
|
||||
#include <ripple/module/core/functional/LoadMonitor.cpp>
|
||||
|
||||
#include <ripple/module/core/functional/Job.cpp>
|
||||
#include <ripple/module/core/functional/JobQueue.cpp>
|
||||
42
src/ripple/unity/core.h
Normal file
42
src/ripple/unity/core.h
Normal file
@@ -0,0 +1,42 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_CORE_H_INCLUDED
|
||||
#define RIPPLE_CORE_H_INCLUDED
|
||||
|
||||
#include <ripple/unity/basics.h>
|
||||
#include <ripple/unity/data.h>
|
||||
|
||||
#include <beast/http/URL.h> // for Config
|
||||
#include <beast/Insight.h>
|
||||
|
||||
#include <ripple/resource/api/LegacyFees.h>
|
||||
|
||||
#include <ripple/module/core/nodestore/NodeStore.h>
|
||||
|
||||
#include <ripple/module/core/functional/ConfigSections.h>
|
||||
#include <ripple/module/core/functional/Config.h>
|
||||
#include <ripple/module/core/functional/LoadFeeTrack.h>
|
||||
#include <ripple/module/core/functional/LoadEvent.h>
|
||||
#include <ripple/module/core/functional/LoadMonitor.h>
|
||||
|
||||
#include <ripple/module/core/functional/Job.h>
|
||||
#include <ripple/module/core/functional/JobQueue.h>
|
||||
|
||||
#endif
|
||||
92
src/ripple/unity/data.cpp
Normal file
92
src/ripple/unity/data.cpp
Normal file
@@ -0,0 +1,92 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/data.h>
|
||||
|
||||
//#include <cmath>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/algorithm/string/predicate.hpp>
|
||||
#include <boost/algorithm/string/split.hpp>
|
||||
#include <boost/algorithm/string/trim.hpp>
|
||||
#include <boost/algorithm/string/classification.hpp>
|
||||
#include <boost/format.hpp>
|
||||
#include <boost/foreach.hpp>
|
||||
#include <boost/functional/hash.hpp>
|
||||
#include <boost/range/adaptor/copied.hpp>
|
||||
#include <boost/regex.hpp>
|
||||
#include <boost/thread/mutex.hpp>
|
||||
|
||||
#include <openssl/ec.h>
|
||||
#include <openssl/bn.h>
|
||||
#include <openssl/ecdsa.h>
|
||||
#include <openssl/pem.h>
|
||||
#include <openssl/hmac.h>
|
||||
#include <openssl/err.h>
|
||||
|
||||
#include <ripple/unity/sslutil.h>
|
||||
#include <ripple/module/rpc/api/ErrorCodes.h>
|
||||
#include <ripple/common/jsonrpc_fields.h>
|
||||
|
||||
// VFALCO TODO fix these warnings!
|
||||
#if BEAST_MSVC
|
||||
#pragma warning (push)
|
||||
#pragma warning (disable: 4018) // signed/unsigned mismatch
|
||||
#endif
|
||||
|
||||
#ifdef min
|
||||
#undef min
|
||||
#endif
|
||||
|
||||
#include <ripple/module/data/protocol/STParsedJSON.cpp>
|
||||
|
||||
#include <ripple/module/data/crypto/CKey.h> // needs RippleAddress VFALCO TODO remove this dependency cycle
|
||||
#include <ripple/module/data/crypto/RFC1751.h>
|
||||
|
||||
#include <ripple/module/data/crypto/CKey.cpp>
|
||||
#include <ripple/module/data/crypto/CKeyDeterministic.cpp>
|
||||
#include <ripple/module/data/crypto/CKeyECIES.cpp>
|
||||
#include <ripple/module/data/crypto/Base58Data.cpp>
|
||||
#include <ripple/module/data/crypto/RFC1751.cpp>
|
||||
|
||||
#include <ripple/module/data/protocol/BuildInfo.cpp>
|
||||
#include <ripple/module/data/protocol/FieldNames.cpp>
|
||||
#include <ripple/module/data/protocol/HashPrefix.cpp>
|
||||
#include <ripple/module/data/protocol/LedgerFormats.cpp>
|
||||
#include <ripple/module/data/protocol/RippleAddress.cpp>
|
||||
#include <ripple/module/data/protocol/SerializedTypes.cpp>
|
||||
#include <ripple/module/data/protocol/Serializer.cpp>
|
||||
#include <ripple/module/data/protocol/SerializedObjectTemplate.cpp>
|
||||
#include <ripple/module/data/protocol/SerializedObject.cpp>
|
||||
#include <ripple/module/data/protocol/TER.cpp>
|
||||
#include <ripple/module/data/protocol/TxFormats.cpp>
|
||||
|
||||
// These are for STAmount
|
||||
static const std::uint64_t tenTo14 = 100000000000000ull;
|
||||
static const std::uint64_t tenTo14m1 = tenTo14 - 1;
|
||||
static const std::uint64_t tenTo17 = tenTo14 * 1000;
|
||||
static const std::uint64_t tenTo17m1 = tenTo17 - 1;
|
||||
#include <ripple/module/data/protocol/STAmount.cpp>
|
||||
#include <ripple/module/data/protocol/STAmountRound.cpp>
|
||||
|
||||
#if BEAST_MSVC
|
||||
#pragma warning (pop)
|
||||
#endif
|
||||
105
src/ripple/unity/data.h
Normal file
105
src/ripple/unity/data.h
Normal file
@@ -0,0 +1,105 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_DATA_H_INCLUDED
|
||||
#define RIPPLE_DATA_H_INCLUDED
|
||||
|
||||
#include <ripple/unity/basics.h>
|
||||
#include <ripple/unity/json.h>
|
||||
#include <ripple/sslutil/api/ECDSACanonical.h>
|
||||
|
||||
struct bignum_st;
|
||||
typedef struct bignum_st BIGNUM;
|
||||
|
||||
#include <ripple/module/data/crypto/Base58Data.h>
|
||||
#include <ripple/module/data/crypto/RFC1751.h>
|
||||
#include <ripple/module/data/protocol/BuildInfo.h>
|
||||
#include <ripple/module/data/protocol/FieldNames.h>
|
||||
#include <ripple/module/data/protocol/HashPrefix.h>
|
||||
#include <ripple/module/data/protocol/Protocol.h>
|
||||
#include <ripple/module/data/protocol/RippleAddress.h>
|
||||
#include <ripple/module/data/protocol/RippleSystem.h>
|
||||
#include <ripple/module/data/protocol/Serializer.h> // needs CKey
|
||||
#include <ripple/module/data/protocol/TER.h>
|
||||
#include <ripple/module/data/protocol/SerializedTypes.h> // needs Serializer, TER
|
||||
#include <ripple/module/data/protocol/SerializedObjectTemplate.h>
|
||||
#include <ripple/module/data/protocol/KnownFormats.h>
|
||||
#include <ripple/module/data/protocol/LedgerFormats.h> // needs SOTemplate from SerializedObjectTemplate
|
||||
#include <ripple/module/data/protocol/TxFormats.h>
|
||||
#include <ripple/module/data/protocol/SerializedObject.h>
|
||||
#include <ripple/module/data/protocol/TxFlags.h>
|
||||
|
||||
#include <ripple/module/data/utility/UptimeTimerAdapter.h>
|
||||
|
||||
#include <ripple/module/data/protocol/STParsedJSON.h>
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace boost
|
||||
{
|
||||
template <>
|
||||
struct range_mutable_iterator <ripple::STPath>
|
||||
{
|
||||
typedef std::vector <ripple::STPathElement>::iterator type;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct range_const_iterator <ripple::STPath>
|
||||
{
|
||||
typedef std::vector <ripple::STPathElement>::const_iterator type;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct range_mutable_iterator <ripple::STPathSet>
|
||||
{
|
||||
typedef std::vector <ripple::STPath>::iterator type;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct range_const_iterator <ripple::STPathSet>
|
||||
{
|
||||
typedef std::vector <ripple::STPath>::const_iterator type;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct range_mutable_iterator <ripple::STObject>
|
||||
{
|
||||
typedef ripple::STObject::iterator type;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct range_const_iterator <ripple::STObject>
|
||||
{
|
||||
typedef ripple::STObject::const_iterator type;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct range_mutable_iterator <ripple::STArray>
|
||||
{
|
||||
typedef ripple::STArray::iterator type;
|
||||
};
|
||||
|
||||
template <>
|
||||
struct range_const_iterator <ripple::STArray>
|
||||
{
|
||||
typedef ripple::STArray::const_iterator type;
|
||||
};
|
||||
}
|
||||
|
||||
#endif
|
||||
38
src/ripple/unity/http.cpp
Normal file
38
src/ripple/unity/http.cpp
Normal file
@@ -0,0 +1,38 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/http.h>
|
||||
|
||||
#include <ripple/unity/net.h>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/asio.hpp>
|
||||
#include <boost/optional.hpp>
|
||||
|
||||
#include <ripple/http/impl/Port.cpp>
|
||||
#include <ripple/http/impl/ScopedStream.cpp>
|
||||
|
||||
#include <ripple/http/impl/Types.h>
|
||||
#include <ripple/http/impl/ServerImpl.h>
|
||||
#include <ripple/http/impl/Peer.h>
|
||||
#include <ripple/http/impl/Door.h>
|
||||
#include <ripple/http/impl/ServerImpl.cpp>
|
||||
#include <ripple/http/impl/Server.cpp>
|
||||
35
src/ripple/unity/http.h
Normal file
35
src/ripple/unity/http.h
Normal file
@@ -0,0 +1,35 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_HTTP_H_INCLUDED
|
||||
#define RIPPLE_HTTP_H_INCLUDED
|
||||
|
||||
// VFALCO This entire file is deprecated now, I'm working on a replacement
|
||||
|
||||
// VFALCO NOTE this sucks that we have to include asio in the header
|
||||
// just for HTTPMessage!!
|
||||
#include <beast/module/asio/asio.h>
|
||||
|
||||
#include <ripple/http/api/Port.h>
|
||||
#include <ripple/http/api/ScopedStream.h>
|
||||
#include <ripple/http/api/Session.h>
|
||||
#include <ripple/http/api/Handler.h>
|
||||
#include <ripple/http/api/Server.h>
|
||||
|
||||
#endif
|
||||
117
src/ripple/unity/hyperleveldb.cpp
Normal file
117
src/ripple/unity/hyperleveldb.cpp
Normal file
@@ -0,0 +1,117 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
// Unity build file for HyperLevelDB
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/hyperleveldb.h>
|
||||
|
||||
#if RIPPLE_HYPERLEVELDB_AVAILABLE
|
||||
|
||||
// Set the appropriate LevelDB platform macro based on our platform.
|
||||
//
|
||||
#if BEAST_WIN32
|
||||
#define LEVELDB_PLATFORM_WINDOWS
|
||||
|
||||
#else
|
||||
#define LEVELDB_PLATFORM_POSIX
|
||||
|
||||
#if BEAST_MAC || BEAST_IOS
|
||||
#define OS_MACOSX
|
||||
|
||||
// VFALCO TODO Distinguish between BEAST_BSD and BEAST_FREEBSD
|
||||
#elif BEAST_BSD
|
||||
#define OS_FREEBSD
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#if BEAST_GCC
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wreorder"
|
||||
#pragma GCC diagnostic ignored "-Wunused-variable"
|
||||
#pragma GCC diagnostic ignored "-Wunused-but-set-variable"
|
||||
#endif
|
||||
|
||||
// Compile HyperLevelDB without debugging unless specifically requested
|
||||
#if !defined (NDEBUG) && !defined (RIPPLE_DEBUG_HYPERLEVELDB)
|
||||
#define NDEBUG
|
||||
#endif
|
||||
|
||||
#include <hyperleveldb/db/builder.cc>
|
||||
#include <hyperleveldb/db/db_impl.cc>
|
||||
#include <hyperleveldb/db/db_iter.cc>
|
||||
#include <hyperleveldb/db/dbformat.cc>
|
||||
#include <hyperleveldb/db/filename.cc>
|
||||
#include <hyperleveldb/db/log_reader.cc>
|
||||
#include <hyperleveldb/db/log_writer.cc>
|
||||
#include <hyperleveldb/db/memtable.cc>
|
||||
#include <hyperleveldb/db/repair.cc>
|
||||
#include <hyperleveldb/db/replay_iterator.cc>
|
||||
#include <hyperleveldb/db/table_cache.cc>
|
||||
#include <hyperleveldb/db/version_edit.cc>
|
||||
#include <hyperleveldb/db/version_set.cc>
|
||||
#include <hyperleveldb/db/write_batch.cc>
|
||||
|
||||
#include <hyperleveldb/table/block.cc>
|
||||
#include <hyperleveldb/table/block_builder.cc>
|
||||
#include <hyperleveldb/table/filter_block.cc>
|
||||
#include <hyperleveldb/table/format.cc>
|
||||
#include <hyperleveldb/table/iterator.cc>
|
||||
#include <hyperleveldb/table/merger.cc>
|
||||
#include <hyperleveldb/table/table.cc>
|
||||
#include <hyperleveldb/table/table_builder.cc>
|
||||
#include <hyperleveldb/table/two_level_iterator.cc>
|
||||
|
||||
#include <hyperleveldb/util/arena.cc>
|
||||
#include <hyperleveldb/util/bloom.cc>
|
||||
#include <hyperleveldb/util/cache.cc>
|
||||
#include <hyperleveldb/util/coding.cc>
|
||||
#include <hyperleveldb/util/comparator.cc>
|
||||
#include <hyperleveldb/util/crc32c.cc>
|
||||
#include <hyperleveldb/util/env.cc>
|
||||
#include <hyperleveldb/util/filter_policy.cc>
|
||||
#include <hyperleveldb/util/hash.cc>
|
||||
#include <hyperleveldb/util/histogram.cc>
|
||||
#include <hyperleveldb/util/logging.cc>
|
||||
#include <hyperleveldb/util/options.cc>
|
||||
#include <hyperleveldb/util/status.cc>
|
||||
|
||||
// Platform Specific
|
||||
|
||||
#if defined (LEVELDB_PLATFORM_WINDOWS)
|
||||
#include <hyperleveldb/util/env_win.cc>
|
||||
#include <hyperleveldb/port/port_win.cc>
|
||||
|
||||
#elif defined (LEVELDB_PLATFORM_POSIX)
|
||||
#include <hyperleveldb/util/env_posix.cc>
|
||||
#include <hyperleveldb/port/port_posix.cc>
|
||||
|
||||
#elif defined (LEVELDB_PLATFORM_ANDROID)
|
||||
# error Missing Android port!
|
||||
|
||||
#endif
|
||||
|
||||
#if BEAST_GCC
|
||||
#pragma GCC diagnostic pop
|
||||
#endif
|
||||
|
||||
#endif
|
||||
40
src/ripple/unity/hyperleveldb.h
Normal file
40
src/ripple/unity/hyperleveldb.h
Normal file
@@ -0,0 +1,40 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_HYPERLEVELDB_H_INCLUDED
|
||||
#define RIPPLE_HYPERLEVELDB_H_INCLUDED
|
||||
|
||||
#include <beast/Config.h>
|
||||
|
||||
#if ! BEAST_WIN32
|
||||
|
||||
#define RIPPLE_HYPERLEVELDB_AVAILABLE 1
|
||||
|
||||
#include <hyperleveldb/hyperleveldb/cache.h>
|
||||
#include <hyperleveldb/hyperleveldb/filter_policy.h>
|
||||
#include <hyperleveldb/hyperleveldb/db.h>
|
||||
#include <hyperleveldb/hyperleveldb/write_batch.h>
|
||||
|
||||
#else
|
||||
|
||||
#define RIPPLE_HYPERLEVELDB_AVAILABLE 0
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
49
src/ripple/unity/json.cpp
Normal file
49
src/ripple/unity/json.cpp
Normal file
@@ -0,0 +1,49 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <cassert>
|
||||
#include <cstdlib>
|
||||
#include <iomanip>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
|
||||
// For json/
|
||||
//
|
||||
#ifdef JSON_USE_CPPTL
|
||||
#include <cpptl/conststring.h>
|
||||
#endif
|
||||
#ifndef JSON_USE_SIMPLE_INTERNAL_ALLOCATOR
|
||||
#include <ripple/json/impl/json_batchallocator.h>
|
||||
#endif
|
||||
|
||||
#include <ripple/unity/json.h>
|
||||
|
||||
#define JSON_ASSERT_UNREACHABLE assert( false )
|
||||
#define JSON_ASSERT( condition ) assert( condition ); // @todo <= change this into an exception throw
|
||||
#define JSON_ASSERT_MESSAGE( condition, message ) if (!( condition )) throw std::runtime_error( message );
|
||||
|
||||
#include <ripple/json/impl/json_reader.cpp>
|
||||
#include <ripple/json/impl/json_value.cpp>
|
||||
#include <ripple/json/impl/json_writer.cpp>
|
||||
|
||||
#include <ripple/json/impl/Tests.cpp>
|
||||
|
||||
#include <ripple/json/impl/JsonPropertyStream.cpp>
|
||||
53
src/ripple/unity/json.h
Normal file
53
src/ripple/unity/json.h
Normal file
@@ -0,0 +1,53 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_JSON_H_INCLUDED
|
||||
#define RIPPLE_JSON_H_INCLUDED
|
||||
|
||||
#include <beast/Config.h>
|
||||
|
||||
#include <beast/strings/String.h>
|
||||
#include <beast/utility/PropertyStream.h>
|
||||
|
||||
#include <deque>
|
||||
#include <stack>
|
||||
#include <vector>
|
||||
|
||||
// For json/
|
||||
//
|
||||
// VFALCO TODO Clean up these one-offs
|
||||
#include <ripple/json/api/json_config.h> // Needed before these cpptl includes
|
||||
#ifndef JSON_USE_CPPTL_SMALLMAP
|
||||
#include <map>
|
||||
#else
|
||||
#include <cpptl/smallmap.h>
|
||||
#endif
|
||||
#ifdef JSON_USE_CPPTL
|
||||
#include <cpptl/forwards.h>
|
||||
#endif
|
||||
|
||||
#include <ripple/json/api/json_forwards.h>
|
||||
#include <ripple/json/api/json_features.h>
|
||||
#include <ripple/json/api/json_value.h>
|
||||
#include <ripple/json/api/json_reader.h>
|
||||
#include <ripple/json/api/json_writer.h>
|
||||
|
||||
#include <ripple/json/api/JsonPropertyStream.h>
|
||||
|
||||
#endif
|
||||
98
src/ripple/unity/leveldb.cpp
Normal file
98
src/ripple/unity/leveldb.cpp
Normal file
@@ -0,0 +1,98 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
// Unity build file for LevelDB
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/leveldb.h>
|
||||
|
||||
#include <beast/Config.h>
|
||||
|
||||
// Set the appropriate LevelDB platform macro based on our platform.
|
||||
//
|
||||
#if BEAST_WIN32
|
||||
#define LEVELDB_PLATFORM_WINDOWS
|
||||
|
||||
#else
|
||||
#define LEVELDB_PLATFORM_POSIX
|
||||
|
||||
#if BEAST_MAC || BEAST_IOS
|
||||
#define OS_MACOSX
|
||||
|
||||
// VFALCO TODO Distinguish between BEAST_BSD and BEAST_FREEBSD
|
||||
#elif BEAST_BSD
|
||||
#define OS_FREEBSD
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#include <leveldb/db/builder.cc>
|
||||
#include <leveldb/db/db_impl.cc>
|
||||
#include <leveldb/db/db_iter.cc>
|
||||
#include <leveldb/db/dbformat.cc>
|
||||
#include <leveldb/db/filename.cc>
|
||||
#include <leveldb/db/log_reader.cc>
|
||||
#include <leveldb/db/log_writer.cc>
|
||||
#include <leveldb/db/memtable.cc>
|
||||
#include <leveldb/db/repair.cc>
|
||||
#include <leveldb/db/table_cache.cc>
|
||||
#include <leveldb/db/version_edit.cc>
|
||||
#include <leveldb/db/version_set.cc>
|
||||
#include <leveldb/db/write_batch.cc>
|
||||
|
||||
#include <leveldb/table/block.cc>
|
||||
#include <leveldb/table/block_builder.cc>
|
||||
#include <leveldb/table/filter_block.cc>
|
||||
#include <leveldb/table/format.cc>
|
||||
#include <leveldb/table/iterator.cc>
|
||||
#include <leveldb/table/merger.cc>
|
||||
#include <leveldb/table/table.cc>
|
||||
#include <leveldb/table/table_builder.cc>
|
||||
#include <leveldb/table/two_level_iterator.cc>
|
||||
|
||||
#include <leveldb/util/arena.cc>
|
||||
#include <leveldb/util/bloom.cc>
|
||||
#include <leveldb/util/cache.cc>
|
||||
#include <leveldb/util/coding.cc>
|
||||
#include <leveldb/util/comparator.cc>
|
||||
#include <leveldb/util/crc32c.cc>
|
||||
#include <leveldb/util/env.cc>
|
||||
#include <leveldb/util/filter_policy.cc>
|
||||
#include <leveldb/util/hash.cc>
|
||||
#include <leveldb/util/histogram.cc>
|
||||
#include <leveldb/util/logging.cc>
|
||||
#include <leveldb/util/options.cc>
|
||||
#include <leveldb/util/status.cc>
|
||||
|
||||
// Platform Specific
|
||||
|
||||
#if defined (LEVELDB_PLATFORM_WINDOWS)
|
||||
#include <leveldb/util/env_win.cc>
|
||||
#include <leveldb/port/port_win.cc>
|
||||
|
||||
#elif defined (LEVELDB_PLATFORM_POSIX)
|
||||
#include <leveldb/util/env_posix.cc>
|
||||
#include <leveldb/port/port_posix.cc>
|
||||
|
||||
#elif defined (LEVELDB_PLATFORM_ANDROID)
|
||||
# error Missing Android port!
|
||||
|
||||
#endif
|
||||
29
src/ripple/unity/leveldb.h
Normal file
29
src/ripple/unity/leveldb.h
Normal file
@@ -0,0 +1,29 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_LEVELDB_H_INCLUDED
|
||||
#define RIPPLE_LEVELDB_H_INCLUDED
|
||||
|
||||
#define SNAPPY
|
||||
#include "leveldb/cache.h"
|
||||
#include "leveldb/filter_policy.h"
|
||||
#include "leveldb/db.h"
|
||||
#include "leveldb/write_batch.h"
|
||||
|
||||
#endif
|
||||
64
src/ripple/unity/net.cpp
Normal file
64
src/ripple/unity/net.cpp
Normal file
@@ -0,0 +1,64 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
/** Add this to get the @ref ripple_net module.
|
||||
|
||||
@file ripple_net.cpp
|
||||
@ingroup ripple_net
|
||||
*/
|
||||
|
||||
#undef DEPRECATED_IN_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#define DEPRECATED_IN_MAC_OS_X_VERSION_10_7_AND_LATER /**/
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/version.hpp>
|
||||
#include <boost/asio/io_service.hpp>
|
||||
#include <boost/asio/ssl.hpp>
|
||||
#include <boost/asio.hpp>
|
||||
#include <boost/make_shared.hpp>
|
||||
#include <boost/bind.hpp>
|
||||
#include <boost/array.hpp>
|
||||
#include <boost/foreach.hpp>
|
||||
#include <boost/mpl/at.hpp>
|
||||
#include <boost/mpl/vector.hpp>
|
||||
|
||||
#include <ripple/unity/net.h>
|
||||
|
||||
#include <ripple/unity/websocket.h> // for HTTPClient, RPCDoor
|
||||
|
||||
// VFALCO NOTE This is the "new new new" where individual headers are included
|
||||
// directly (instead of the module header). The corresponding .cpp
|
||||
// still uses the unity style inclusion.
|
||||
//
|
||||
#include <ripple/module/rpc/api/ErrorCodes.h>
|
||||
#include <ripple/common/jsonrpc_fields.h>
|
||||
|
||||
#include <ripple/module/net/basics/HTTPRequest.cpp>
|
||||
#include <ripple/module/net/basics/HTTPClient.cpp>
|
||||
#include <ripple/module/net/basics/impl/RPCServerImp.h>
|
||||
#include <ripple/module/net/basics/SNTPClient.cpp>
|
||||
#include <ripple/module/net/rpc/RPCCall.cpp>
|
||||
#include <ripple/module/net/rpc/RPCErr.cpp>
|
||||
#include <ripple/module/net/rpc/RPCSub.cpp>
|
||||
#include <ripple/module/net/rpc/RPCUtil.cpp>
|
||||
#include <ripple/module/net/rpc/InfoSub.cpp>
|
||||
|
||||
#include <ripple/module/net/basics/RPCDoor.cpp>
|
||||
50
src/ripple/unity/net.h
Normal file
50
src/ripple/unity/net.h
Normal file
@@ -0,0 +1,50 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_NET_H_INCLUDED
|
||||
#define RIPPLE_NET_H_INCLUDED
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/unordered_set.hpp> // For InfoSub
|
||||
|
||||
#include <boost/asio.hpp>
|
||||
#undef DEPRECATED_IN_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#define DEPRECATED_IN_MAC_OS_X_VERSION_10_7_AND_LATER /**/
|
||||
#include <boost/asio/ssl.hpp>
|
||||
|
||||
#include <ripple/unity/resource.h>
|
||||
|
||||
#include <ripple/unity/basics.h>
|
||||
#include <ripple/unity/core.h>
|
||||
#include <ripple/unity/data.h>
|
||||
#include <ripple/module/websocket/autosocket/AutoSocket.h>
|
||||
|
||||
#include <ripple/module/net/basics/HTTPRequest.h>
|
||||
#include <ripple/module/net/basics/HTTPClient.h>
|
||||
#include <ripple/module/net/basics/RPCServer.h>
|
||||
#include <ripple/module/net/basics/RPCDoor.h>
|
||||
#include <ripple/module/net/basics/SNTPClient.h>
|
||||
|
||||
#include <ripple/module/net/rpc/RPCErr.h>
|
||||
#include <ripple/module/net/rpc/RPCUtil.h>
|
||||
#include <ripple/module/net/rpc/RPCCall.h>
|
||||
#include <ripple/module/net/rpc/InfoSub.h>
|
||||
#include <ripple/module/net/rpc/RPCSub.h>
|
||||
|
||||
#endif
|
||||
26
src/ripple/unity/overlay.cpp
Normal file
26
src/ripple/unity/overlay.cpp
Normal file
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/module/overlay/impl/Message.cpp>
|
||||
#include <ripple/module/overlay/impl/OverlayImpl.cpp>
|
||||
#include <ripple/module/overlay/impl/PeerImp.h>
|
||||
#include <ripple/module/overlay/impl/PeerDoor.cpp>
|
||||
|
||||
87
src/ripple/unity/peerfinder.cpp
Normal file
87
src/ripple/unity/peerfinder.cpp
Normal file
@@ -0,0 +1,87 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/peerfinder.h>
|
||||
|
||||
#include <ripple/algorithm/api/CycledSet.h>
|
||||
#include <ripple/common/Resolver.h>
|
||||
|
||||
#include <deque>
|
||||
#include <fstream>
|
||||
#include <iomanip>
|
||||
#include <random>
|
||||
#include <set>
|
||||
#include <unordered_set>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/array.hpp>
|
||||
#include <boost/optional.hpp>
|
||||
#include <boost/regex.hpp>
|
||||
|
||||
#include <beast/module/sqdb/sqdb.h>
|
||||
#include <beast/module/asio/asio.h>
|
||||
|
||||
#include <beast/boost/ErrorCode.h>
|
||||
#include <beast/chrono/chrono_io.h>
|
||||
|
||||
#include <ripple/peerfinder/impl/iosformat.h> // VFALCO NOTE move to beast
|
||||
|
||||
#ifndef NDEBUG
|
||||
# define consistency_check(cond) bassert(cond)
|
||||
#else
|
||||
# define consistency_check(cond)
|
||||
#endif
|
||||
|
||||
#include <ripple/peerfinder/impl/PrivateTypes.h>
|
||||
#include <ripple/peerfinder/impl/Tuning.h>
|
||||
#include <ripple/peerfinder/impl/Checker.h>
|
||||
#include <ripple/peerfinder/impl/CheckerAdapter.h>
|
||||
#include <ripple/peerfinder/impl/Livecache.h>
|
||||
#include <ripple/peerfinder/impl/SlotImp.h>
|
||||
#include <ripple/peerfinder/impl/Counts.h>
|
||||
#include <ripple/peerfinder/impl/Source.h>
|
||||
#include <ripple/peerfinder/impl/SourceStrings.h>
|
||||
#include <ripple/peerfinder/impl/Store.h>
|
||||
#include <ripple/peerfinder/impl/Bootcache.h>
|
||||
#include <ripple/peerfinder/impl/StoreSqdb.h>
|
||||
#include <ripple/peerfinder/impl/Reporting.h>
|
||||
#include <ripple/peerfinder/impl/Logic.h>
|
||||
|
||||
#include <ripple/peerfinder/impl/Bootcache.cpp>
|
||||
#include <ripple/peerfinder/impl/Checker.cpp>
|
||||
#include <ripple/peerfinder/impl/Config.cpp>
|
||||
#include <ripple/peerfinder/impl/ConnectHandouts.cpp>
|
||||
#include <ripple/peerfinder/impl/Endpoint.cpp>
|
||||
#include <ripple/peerfinder/impl/Livecache.cpp>
|
||||
#include <ripple/peerfinder/impl/Manager.cpp>
|
||||
#include <ripple/peerfinder/impl/RedirectHandouts.cpp>
|
||||
#include <ripple/peerfinder/impl/SlotHandouts.cpp>
|
||||
#include <ripple/peerfinder/impl/SlotImp.cpp>
|
||||
#include <ripple/peerfinder/impl/SourceStrings.cpp>
|
||||
|
||||
#include <ripple/peerfinder/sim/GraphAlgorithms.h>
|
||||
#include <ripple/peerfinder/sim/WrappedSink.h>
|
||||
#include <ripple/peerfinder/sim/Predicates.h>
|
||||
#include <ripple/peerfinder/sim/FunctionQueue.h>
|
||||
#include <ripple/peerfinder/sim/Message.h>
|
||||
#include <ripple/peerfinder/sim/NodeSnapshot.h>
|
||||
#include <ripple/peerfinder/sim/Params.h>
|
||||
#include <ripple/peerfinder/sim/Tests.cpp>
|
||||
34
src/ripple/unity/peerfinder.h
Normal file
34
src/ripple/unity/peerfinder.h
Normal file
@@ -0,0 +1,34 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_PEERFINDER_H_INCLUDED
|
||||
#define RIPPLE_PEERFINDER_H_INCLUDED
|
||||
|
||||
#include <ripple/unity/sitefiles.h>
|
||||
|
||||
#include <ripple/types/api/RipplePublicKey.h>
|
||||
|
||||
#include <ripple/peerfinder/api/Slot.h>
|
||||
#include <ripple/peerfinder/api/Endpoint.h>
|
||||
#include <ripple/peerfinder/api/Types.h>
|
||||
#include <ripple/peerfinder/api/Callback.h>
|
||||
#include <ripple/peerfinder/api/Config.h>
|
||||
#include <ripple/peerfinder/api/Manager.h>
|
||||
|
||||
#endif
|
||||
57
src/ripple/unity/protobuf.cpp
Normal file
57
src/ripple/unity/protobuf.cpp
Normal file
@@ -0,0 +1,57 @@
|
||||
// Unity build file for libprotobuf by Vinnie Falco <vinnie.falco@gmail.com>
|
||||
//
|
||||
|
||||
#ifdef _MSC_VER
|
||||
|
||||
#ifdef _MSC_VER // MSVC
|
||||
# pragma warning (push)
|
||||
# pragma warning (disable: 4018) // signed/unsigned mismatch
|
||||
# pragma warning (disable: 4244) // conversion, possible loss of data
|
||||
# pragma warning (disable: 4800) // forcing value to bool
|
||||
# pragma warning (disable: 4996) // deprecated POSIX name
|
||||
#endif
|
||||
|
||||
#include "google/protobuf/descriptor.cc"
|
||||
#include "google/protobuf/descriptor.pb.cc"
|
||||
#include "google/protobuf/descriptor_database.cc"
|
||||
#include "google/protobuf/dynamic_message.cc"
|
||||
#include "google/protobuf/extension_set.cc"
|
||||
#include "google/protobuf/extension_set_heavy.cc"
|
||||
#include "google/protobuf/generated_message_reflection.cc"
|
||||
#include "google/protobuf/generated_message_util.cc"
|
||||
#include "google/protobuf/message.cc"
|
||||
#include "google/protobuf/message_lite.cc"
|
||||
#include "google/protobuf/reflection_ops.cc"
|
||||
#include "google/protobuf/repeated_field.cc"
|
||||
#include "google/protobuf/service.cc"
|
||||
#include "google/protobuf/text_format.cc"
|
||||
#include "google/protobuf/unknown_field_set.cc"
|
||||
#include "google/protobuf/wire_format.cc"
|
||||
#include "google/protobuf/wire_format_lite.cc"
|
||||
|
||||
#include "google/protobuf/compiler/importer.cc"
|
||||
#include "google/protobuf/compiler/parser.cc"
|
||||
|
||||
#include "google/protobuf/io/coded_stream.cc"
|
||||
#include "google/protobuf/io/gzip_stream.cc"
|
||||
#include "google/protobuf/io/tokenizer.cc"
|
||||
#include "google/protobuf/io/zero_copy_stream.cc"
|
||||
#include "google/protobuf/io/zero_copy_stream_impl.cc"
|
||||
#include "google/protobuf/io/zero_copy_stream_impl_lite.cc"
|
||||
|
||||
#include "google/protobuf/stubs/common.cc"
|
||||
#include "google/protobuf/stubs/once.cc"
|
||||
#include "google/protobuf/stubs/stringprintf.cc"
|
||||
#include "google/protobuf/stubs/structurally_valid.cc"
|
||||
#include "google/protobuf/stubs/strutil.cc"
|
||||
#include "google/protobuf/stubs/substitute.cc"
|
||||
|
||||
#ifdef _MSC_VER // MSVC
|
||||
#include "google/protobuf/stubs/atomicops_internals_x86_msvc.cc"
|
||||
#endif
|
||||
|
||||
#ifdef _MSC_VER // MSVC
|
||||
# pragma warning (pop)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
22
src/ripple/unity/radmap.cpp
Normal file
22
src/ripple/unity/radmap.cpp
Normal file
@@ -0,0 +1,22 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/radmap/impl/BasicFullBelowCache.cpp>
|
||||
26
src/ripple/unity/radmap.h
Normal file
26
src/ripple/unity/radmap.h
Normal file
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_RADMAP_H_INCLUDED
|
||||
#define RIPPLE_RADMAP_H_INCLUDED
|
||||
|
||||
#include <ripple/radmap/api/BasicFullBelowCache.h>
|
||||
#include <ripple/radmap/api/Tuning.h>
|
||||
|
||||
#endif
|
||||
45
src/ripple/unity/resource.cpp
Normal file
45
src/ripple/unity/resource.cpp
Normal file
@@ -0,0 +1,45 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/resource.h>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/utility/base_from_member.hpp>
|
||||
|
||||
#include <ripple/algorithm/api/DecayingSample.h>
|
||||
#include <ripple/common/seconds_clock.h>
|
||||
|
||||
#include <beast/Insight.h>
|
||||
#include <beast/cxx14/memory.h>
|
||||
#include <beast/chrono/chrono_io.h>
|
||||
|
||||
#include <ripple/resource/impl/Fees.cpp>
|
||||
#include <ripple/resource/impl/Kind.h>
|
||||
#include <ripple/resource/impl/Key.h>
|
||||
#include <ripple/resource/impl/Tuning.h>
|
||||
#include <ripple/resource/impl/Entry.h>
|
||||
#include <ripple/resource/impl/Import.h>
|
||||
#include <ripple/resource/impl/Charge.cpp>
|
||||
#include <ripple/resource/impl/Logic.h>
|
||||
#include <ripple/resource/impl/Consumer.cpp>
|
||||
#include <ripple/resource/impl/LegacyFees.cpp>
|
||||
#include <ripple/resource/impl/Manager.cpp>
|
||||
#include <ripple/resource/impl/Tests.cpp>
|
||||
34
src/ripple/unity/resource.h
Normal file
34
src/ripple/unity/resource.h
Normal file
@@ -0,0 +1,34 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_RESOURCE_H_INCLUDED
|
||||
#define RIPPLE_RESOURCE_H_INCLUDED
|
||||
|
||||
#include <ripple/unity/json.h>
|
||||
|
||||
#include <ripple/resource/api/Types.h>
|
||||
#include <ripple/resource/api/Disposition.h>
|
||||
#include <ripple/resource/api/Charge.h>
|
||||
#include <ripple/resource/api/LegacyFees.h>
|
||||
#include <ripple/resource/api/Fees.h>
|
||||
#include <ripple/resource/api/Consumer.h>
|
||||
#include <ripple/resource/api/Gossip.h>
|
||||
#include <ripple/resource/api/Manager.h>
|
||||
|
||||
#endif
|
||||
20
src/ripple/unity/ripple.proto.cpp
Normal file
20
src/ripple/unity/ripple.proto.cpp
Normal file
@@ -0,0 +1,20 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2014 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "ripple.pb.cc"
|
||||
115
src/ripple/unity/rocksdb.cpp
Normal file
115
src/ripple/unity/rocksdb.cpp
Normal file
@@ -0,0 +1,115 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/rocksdb.h>
|
||||
|
||||
#if RIPPLE_ROCKSDB_AVAILABLE
|
||||
|
||||
#if BEAST_WIN32
|
||||
# define ROCKSDB_PLATFORM_WINDOWS
|
||||
#else
|
||||
# define ROCKSDB_PLATFORM_POSIX
|
||||
# if BEAST_MAC || BEAST_IOS
|
||||
# define OS_MACOSX
|
||||
# elif BEAST_BSD
|
||||
# define OS_FREEBSD
|
||||
# else
|
||||
# define OS_LINUX
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if BEAST_GCC
|
||||
# pragma GCC diagnostic push
|
||||
# pragma GCC diagnostic ignored "-Wreorder"
|
||||
# pragma GCC diagnostic ignored "-Wunused-variable"
|
||||
# pragma GCC diagnostic ignored "-Wunused-but-set-variable"
|
||||
#endif
|
||||
|
||||
// Compile RocksDB without debugging unless specifically requested
|
||||
#if !defined (NDEBUG) && !defined (RIPPLE_DEBUG_ROCKSDB)
|
||||
#define NDEBUG
|
||||
#endif
|
||||
|
||||
#include <ripple/rocksdb/rocksdb/db/builder.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/db_filesnapshot.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/dbformat.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/db_impl.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/db_impl_readonly.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/db_iter.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/db_stats_logger.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/filename.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/log_reader.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/log_writer.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/memtable.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/memtablelist.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/merge_helper.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/merge_operator.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/repair.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/table_cache.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/table_properties_collector.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/transaction_log_impl.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/version_edit.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/version_set.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/version_set_reduce_num_levels.cc>
|
||||
#include <ripple/rocksdb/rocksdb/db/write_batch.cc>
|
||||
|
||||
#include <ripple/rocksdb/rocksdb/table/block_based_table_builder.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/block_based_table_factory.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/block_based_table_reader.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/block_builder.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/block.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/filter_block.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/flush_block_policy.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/format.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/iterator.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/merger.cc>
|
||||
#include <ripple/rocksdb/rocksdb/table/two_level_iterator.cc>
|
||||
|
||||
#include <ripple/rocksdb/rocksdb/util/arena_impl.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/auto_roll_logger.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/blob_store.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/bloom.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/cache.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/coding.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/comparator.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/crc32c.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/env.cc>
|
||||
//#include "rocksdb/util/env_hdfs.cc"
|
||||
#include <ripple/rocksdb/rocksdb/util/env_posix.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/filter_policy.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/hash.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/hash_skiplist_rep.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/histogram.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/logging.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/murmurhash.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/options.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/perf_context.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/skiplistrep.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/slice.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/statistics.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/status.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/string_util.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/transformrep.cc>
|
||||
#include <ripple/rocksdb/rocksdb/util/vectorrep.cc>
|
||||
|
||||
#include <ripple/rocksdb/rocksdb/port/port_posix.cc>
|
||||
|
||||
#endif
|
||||
64
src/ripple/unity/rocksdb.h
Normal file
64
src/ripple/unity/rocksdb.h
Normal file
@@ -0,0 +1,64 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_ROCKSDB_H_INCLUDED
|
||||
#define RIPPLE_ROCKSDB_H_INCLUDED
|
||||
|
||||
#include <beast/Config.h>
|
||||
|
||||
#ifndef RIPPLE_ROCKSDB_AVAILABLE
|
||||
# if BEAST_WIN32
|
||||
# define RIPPLE_ROCKSDB_AVAILABLE 0
|
||||
# else
|
||||
# if __cplusplus >= 201103L
|
||||
# define RIPPLE_ROCKSDB_AVAILABLE 1
|
||||
# else
|
||||
# define RIPPLE_ROCKSDB_AVAILABLE 0
|
||||
# endif
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if RIPPLE_ROCKSDB_AVAILABLE
|
||||
#define SNAPPY
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/arena.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/cache.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/compaction_filter.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/comparator.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/db.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/env.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/filter_policy.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/flush_block_policy.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/iterator.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/memtablerep.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/merge_operator.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/options.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/perf_context.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/slice.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/slice_transform.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/statistics.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/status.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/table.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/table_properties.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/transaction_log.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/types.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/universal_compaction.h>
|
||||
#include <ripple/rocksdb/rocksdb/include/rocksdb/write_batch.h>
|
||||
#endif
|
||||
|
||||
#endif
|
||||
30
src/ripple/unity/rpcx.cpp
Normal file
30
src/ripple/unity/rpcx.cpp
Normal file
@@ -0,0 +1,30 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#include <ripple/unity/rpcx.h>
|
||||
|
||||
// Unfortunate but necessary since RPC handlers can literally do anything
|
||||
#include <ripple/unity/app.h>
|
||||
|
||||
#include <ripple/module/rpc/impl/ErrorCodes.cpp>
|
||||
#include <ripple/module/rpc/impl/Manager.cpp>
|
||||
|
||||
|
||||
27
src/ripple/unity/rpcx.h
Normal file
27
src/ripple/unity/rpcx.h
Normal file
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_RPC_H_INCLUDED
|
||||
#define RIPPLE_RPC_H_INCLUDED
|
||||
|
||||
#include <ripple/module/rpc/api/ErrorCodes.h>
|
||||
#include <ripple/module/rpc/api/Manager.h>
|
||||
#include <ripple/module/rpc/api/Request.h>
|
||||
|
||||
#endif
|
||||
35
src/ripple/unity/sitefiles.cpp
Normal file
35
src/ripple/unity/sitefiles.cpp
Normal file
@@ -0,0 +1,35 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/sitefiles.h>
|
||||
|
||||
#include <beast/module/asio/asio.h> // HTTPClientBase
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/regex.hpp>
|
||||
|
||||
#include <set>
|
||||
|
||||
#include <ripple/sitefiles/impl/Site.h>
|
||||
#include <ripple/sitefiles/impl/Logic.h>
|
||||
#include <ripple/sitefiles/impl/Manager.cpp>
|
||||
#include <ripple/sitefiles/impl/Section.cpp>
|
||||
#include <ripple/sitefiles/impl/SiteFile.cpp>
|
||||
35
src/ripple/unity/sitefiles.h
Normal file
35
src/ripple/unity/sitefiles.h
Normal file
@@ -0,0 +1,35 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_SITEFILES_H_INCLUDED
|
||||
#define RIPPLE_SITEFILES_H_INCLUDED
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
|
||||
#include <beast/http/URL.h>
|
||||
#include <beast/Threads.h>
|
||||
|
||||
#include <ripple/sitefiles/api/Section.h>
|
||||
#include <ripple/sitefiles/api/SiteFile.h>
|
||||
#include <ripple/sitefiles/api/Listener.h>
|
||||
#include <ripple/sitefiles/api/Manager.h>
|
||||
|
||||
#endif
|
||||
31
src/ripple/unity/snappy.cpp
Normal file
31
src/ripple/unity/snappy.cpp
Normal file
@@ -0,0 +1,31 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2014 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#include <cstddef>
|
||||
namespace snappy {
|
||||
typedef std::ptrdiff_t ssize_t;
|
||||
}
|
||||
#endif
|
||||
|
||||
#include <snappy/snappy/snappy.cc>
|
||||
#include <snappy/snappy/snappy-sinksource.cc>
|
||||
#include <snappy/snappy/snappy-stubs-internal.cc>
|
||||
27
src/ripple/unity/sslutil.cpp
Normal file
27
src/ripple/unity/sslutil.cpp
Normal file
@@ -0,0 +1,27 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/sslutil.h>
|
||||
|
||||
#include <ripple/sslutil/impl/CBigNum.cpp>
|
||||
#include <ripple/sslutil/impl/ECDSACanonical.cpp>
|
||||
#include <ripple/sslutil/impl/DHUtil.cpp>
|
||||
#include <ripple/sslutil/impl/HashUtilities.cpp>
|
||||
37
src/ripple/unity/sslutil.h
Normal file
37
src/ripple/unity/sslutil.h
Normal file
@@ -0,0 +1,37 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_SSLUTIL_H_INCLUDED
|
||||
#define RIPPLE_SSLUTIL_H_INCLUDED
|
||||
|
||||
#include <ripple/unity/types.h>
|
||||
|
||||
#include <openssl/bn.h>
|
||||
#include <openssl/dh.h>
|
||||
#include <openssl/ripemd.h>
|
||||
#include <openssl/sha.h>
|
||||
|
||||
#include <ripple/sslutil/api/bignum_error.h>
|
||||
#include <ripple/sslutil/api/CAutoBN_CTX.h>
|
||||
#include <ripple/sslutil/api/CBigNum.h>
|
||||
#include <ripple/sslutil/api/DHUtil.h>
|
||||
#include <ripple/sslutil/api/HashUtilities.h>
|
||||
#include <ripple/sslutil/api/ECDSACanonical.h>
|
||||
|
||||
#endif
|
||||
24
src/ripple/unity/testoverlay.cpp
Normal file
24
src/ripple/unity/testoverlay.cpp
Normal file
@@ -0,0 +1,24 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/testoverlay.h>
|
||||
|
||||
#include <ripple/testoverlay/impl/TestOverlay.cpp>
|
||||
56
src/ripple/unity/testoverlay.h
Normal file
56
src/ripple/unity/testoverlay.h
Normal file
@@ -0,0 +1,56 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_TESTOVERLAY_H_INCLUDED
|
||||
#define RIPPLE_TESTOVERLAY_H_INCLUDED
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/unordered_set.hpp>
|
||||
|
||||
#include <beast/module/core/core.h>
|
||||
|
||||
#include <memory>
|
||||
|
||||
/** Provides a template based peer to peer network simulator.
|
||||
|
||||
A TestOverlay::Network simulates an entire peer to peer network.
|
||||
It provides peer connectivity and message passing services, while
|
||||
allowing domain specific customization through user provided types.
|
||||
|
||||
This system is designed to allow business logic to be exercised
|
||||
in unit tests, using a simulated large scale network.
|
||||
*/
|
||||
|
||||
namespace ripple
|
||||
{
|
||||
|
||||
#include <ripple/testoverlay/api/Results.h>
|
||||
#include <ripple/testoverlay/api/SimplePayload.h>
|
||||
#include <ripple/testoverlay/api/MessageType.h>
|
||||
#include <ripple/testoverlay/api/ConnectionType.h>
|
||||
#include <ripple/testoverlay/api/PeerType.h>
|
||||
#include <ripple/testoverlay/api/NetworkType.h>
|
||||
#include <ripple/testoverlay/api/StateBase.h>
|
||||
#include <ripple/testoverlay/api/PeerLogicBase.h>
|
||||
#include <ripple/testoverlay/api/InitPolicy.h>
|
||||
#include <ripple/testoverlay/api/ConfigType.h>
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
52
src/ripple/unity/types.cpp
Normal file
52
src/ripple/unity/types.cpp
Normal file
@@ -0,0 +1,52 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/types.h>
|
||||
#include <ripple/unity/sslutil.h>
|
||||
|
||||
#ifdef BEAST_WIN32
|
||||
#include <Winsock2.h> // for ByteOrder.cpp
|
||||
// <Winsock2.h> defines min, max and does other stupid things
|
||||
# ifdef max
|
||||
# undef max
|
||||
# endif
|
||||
# ifdef min
|
||||
# undef min
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#include <set>
|
||||
#include <map>
|
||||
#include <unordered_set>
|
||||
#include <unordered_map>
|
||||
#include <boost/unordered_set.hpp>
|
||||
|
||||
#include <ripple/types/impl/Base58.cpp>
|
||||
#include <ripple/types/impl/ByteOrder.cpp>
|
||||
#include <ripple/types/impl/RandomNumbers.cpp>
|
||||
#include <ripple/types/impl/strHex.cpp>
|
||||
#include <ripple/types/impl/base_uint.cpp>
|
||||
#include <ripple/types/impl/UInt160.cpp>
|
||||
#include <ripple/types/impl/RippleIdentifierTests.cpp>
|
||||
#include <ripple/types/impl/RippleAssets.cpp>
|
||||
|
||||
#include <ripple/common/tests/cross_offer.test.cpp>
|
||||
|
||||
65
src/ripple/unity/types.h
Normal file
65
src/ripple/unity/types.h
Normal file
@@ -0,0 +1,65 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_TYPES_H_INCLUDED
|
||||
#define RIPPLE_TYPES_H_INCLUDED
|
||||
|
||||
#include <ripple/unity/json.h>
|
||||
|
||||
#include <beast/Crypto.h>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/utility/base_from_member.hpp>
|
||||
#include <boost/functional/hash.hpp>
|
||||
#include <boost/unordered_set.hpp>
|
||||
|
||||
// For ByteOrder
|
||||
#if BEAST_WIN32
|
||||
// (nothing)
|
||||
#elif __APPLE__
|
||||
#include <libkern/OSByteOrder.h>
|
||||
#elif defined(__FreeBSD__) || defined(__NetBSD__)
|
||||
#include <sys/endian.h>
|
||||
#elif defined(__OpenBSD__)
|
||||
#include <sys/types.h>
|
||||
#endif
|
||||
|
||||
#include <ripple/types/api/AgedHistory.h>
|
||||
#include <ripple/types/api/Blob.h>
|
||||
#include <ripple/types/api/Base58.h>
|
||||
#include <ripple/types/api/ByteOrder.h>
|
||||
#include <ripple/types/api/strHex.h>
|
||||
#include <ripple/types/api/UInt160.h>
|
||||
#include <ripple/types/api/RandomNumbers.h>
|
||||
#include <ripple/types/api/HashMaps.h>
|
||||
|
||||
#include <ripple/types/api/IdentifierType.h>
|
||||
#include <ripple/types/api/IdentifierStorage.h>
|
||||
#include <ripple/types/api/CryptoIdentifier.h>
|
||||
#include <ripple/types/api/RippleAccountID.h>
|
||||
#include <ripple/types/api/RippleAccountPublicKey.h>
|
||||
#include <ripple/types/api/RippleAccountPrivateKey.h>
|
||||
#include <ripple/types/api/RippleAssets.h>
|
||||
#include <ripple/types/api/RipplePublicKey.h>
|
||||
#include <ripple/types/api/RipplePrivateKey.h>
|
||||
#include <ripple/types/api/SimpleIdentifier.h>
|
||||
#include <ripple/types/api/RippleLedgerHash.h>
|
||||
#include <ripple/types/api/RipplePublicKeyHash.h>
|
||||
|
||||
#endif
|
||||
61
src/ripple/unity/validators.cpp
Normal file
61
src/ripple/unity/validators.cpp
Normal file
@@ -0,0 +1,61 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include <BeastConfig.h>
|
||||
|
||||
#include <ripple/unity/validators.h>
|
||||
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/regex.hpp>
|
||||
#include <boost/unordered_set.hpp>
|
||||
#include <boost/multi_index_container.hpp>
|
||||
#include <boost/multi_index/hashed_index.hpp>
|
||||
#include <boost/multi_index/key_extractors.hpp>
|
||||
|
||||
#include <set>
|
||||
|
||||
#include <beast/threads/ScopedWrapperContext.h>
|
||||
#include <beast/module/asio/asio.h>
|
||||
#include <beast/module/sqdb/sqdb.h>
|
||||
|
||||
#include <ripple/algorithm/api/CycledSet.h>
|
||||
#include <ripple/unity/testoverlay.h> // for unit test
|
||||
|
||||
#include <ripple/validators/impl/Tuning.h>
|
||||
#include <ripple/validators/impl/ChosenList.h>
|
||||
#include <ripple/validators/impl/Count.h>
|
||||
#include <ripple/validators/impl/SourceFile.h>
|
||||
#include <ripple/validators/impl/SourceStrings.h>
|
||||
#include <ripple/validators/impl/SourceURL.h>
|
||||
#include <ripple/validators/impl/SourceDesc.h>
|
||||
#include <ripple/validators/impl/Store.h>
|
||||
#include <ripple/validators/impl/StoreSqdb.h>
|
||||
#include <ripple/validators/impl/Utilities.h>
|
||||
#include <ripple/validators/impl/Validation.h>
|
||||
#include <ripple/validators/impl/Validator.h>
|
||||
#include <ripple/validators/impl/Logic.h>
|
||||
|
||||
#include <ripple/validators/impl/Manager.cpp>
|
||||
#include <ripple/validators/impl/Source.cpp>
|
||||
#include <ripple/validators/impl/SourceFile.cpp>
|
||||
#include <ripple/validators/impl/SourceStrings.cpp>
|
||||
#include <ripple/validators/impl/SourceURL.cpp>
|
||||
#include <ripple/validators/impl/StoreSqdb.cpp>
|
||||
#include <ripple/validators/impl/Tests.cpp>
|
||||
#include <ripple/validators/impl/Utilities.cpp>
|
||||
31
src/ripple/unity/validators.h
Normal file
31
src/ripple/unity/validators.h
Normal file
@@ -0,0 +1,31 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_VALIDATORS_H_INCLUDED
|
||||
#define RIPPLE_VALIDATORS_H_INCLUDED
|
||||
|
||||
#include <beast/http/URL.h>
|
||||
|
||||
#include <ripple/unity/types.h>
|
||||
|
||||
#include <ripple/validators/api/Types.h>
|
||||
#include <ripple/validators/api/Source.h>
|
||||
#include <ripple/validators/api/Manager.h>
|
||||
|
||||
#endif
|
||||
46
src/ripple/unity/websocket.cpp
Normal file
46
src/ripple/unity/websocket.cpp
Normal file
@@ -0,0 +1,46 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#include "../../BeastConfig.h"
|
||||
|
||||
#ifndef __STDC_LIMIT_MACROS
|
||||
#define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
#include <stdint.h>
|
||||
|
||||
#include <ripple/unity/websocket.h>
|
||||
|
||||
// Unity build file for websocket
|
||||
//
|
||||
|
||||
#include <websocket/src/sha1/sha1.h>
|
||||
|
||||
// Must come first to prevent compile errors
|
||||
#include <websocket/src/uri.cpp>
|
||||
|
||||
#include <websocket/src/base64/base64.cpp>
|
||||
#include <websocket/src/messages/data.cpp>
|
||||
#include <websocket/src/processors/hybi_header.cpp>
|
||||
#include <websocket/src/processors/hybi_util.cpp>
|
||||
#include <websocket/src/md5/md5.c>
|
||||
#include <websocket/src/network_utilities.cpp>
|
||||
#include <websocket/src/sha1/sha1.cpp>
|
||||
|
||||
#include <ripple/module/websocket/autosocket/AutoSocket.cpp>
|
||||
#include <ripple/module/websocket/autosocket/LogWebsockets.cpp>
|
||||
41
src/ripple/unity/websocket.h
Normal file
41
src/ripple/unity/websocket.h
Normal file
@@ -0,0 +1,41 @@
|
||||
//------------------------------------------------------------------------------
|
||||
/*
|
||||
This file is part of rippled: https://github.com/ripple/rippled
|
||||
Copyright (c) 2012, 2013 Ripple Labs Inc.
|
||||
|
||||
Permission to use, copy, modify, and/or distribute this software for any
|
||||
purpose with or without fee is hereby granted, provided that the above
|
||||
copyright notice and this permission notice appear in all copies.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
//==============================================================================
|
||||
|
||||
#ifndef RIPPLE_WEBSOCKET_H_INCLUDED
|
||||
#define RIPPLE_WEBSOCKET_H_INCLUDED
|
||||
|
||||
// needed before inclusion of stdint.h for INT32_MIN/INT32_MAX macros
|
||||
#ifndef __STDC_LIMIT_MACROS
|
||||
#define __STDC_LIMIT_MACROS
|
||||
#endif
|
||||
|
||||
#include <ripple/unity/net.h>
|
||||
|
||||
#include <beast/module/core/text/LexicalCast.h>
|
||||
#include <beast/module/core/system/BeforeBoost.h>
|
||||
#include <boost/asio.hpp>
|
||||
#include <boost/asio/ssl.hpp>
|
||||
|
||||
#include <websocket/src/common.hpp>
|
||||
#include <websocket/src/sockets/socket_base.hpp>
|
||||
#include <websocket/src/sockets/multitls.hpp>
|
||||
#include <websocket/src/websocketpp.hpp>
|
||||
#include <websocket/src/logger/logger.hpp>
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user