Compare commits

...

41 Commits

Author SHA1 Message Date
Ed Hennis
c8eaa6f39e Merge branch 'develop' into ximinez/vault-test 2026-02-18 21:11:39 -04:00
Jingchen
0976b2b68b refactor: Modularize app/tx (#6228) 2026-02-17 18:10:07 +00:00
Jingchen
36240116a5 refactor: Decouple app/tx from Application and Config (#6227)
This change decouples app/tx from `Application` and `Config` to clear the way to moving transactors to `libxrpl`.
2026-02-17 11:29:53 -05:00
Sergey Kuznetsov
958d8f3754 chore: Update clang-format to 21.1.8 (#6352) 2026-02-16 14:31:18 -05:00
Ed Hennis
740a22aeaf Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  chore: Update secp256k1 and openssl (6327)
  chore: Remove unnecessary script (6326)
  refactor: Replace include guards by '#pragma once' (6322)
  chore: Remove unity builds (6300)
  refactor: Add ServiceRegistry to help modularization (6222)
  fix: Deletes expired NFToken offers from ledger (5707)
  chore: Add .zed editor config directory to .gitignore (6317)
  docs: Update API changelog, add APIv2+APIv3 version documentation (6308)
  fix: Restore config changes that broke standalone mode (6301)
  chore: Add upper-case match for ARM64 in CompilationEnv (6315)
  ci: Update hashes of XRPLF/actions (6316)
  chore: Format all cmake files without comments (6294)
  chore: Add cmake-format pre-commit hook (6279)
2026-02-04 16:09:38 -05:00
Ed Hennis
149d9803e2 Fix formatting 2026-01-28 19:36:31 -05:00
Ed Hennis
304b5a1516 Merge branch 'develop' into ximinez/vault-test 2026-01-28 19:09:27 -04:00
Ed Hennis
78ccd2de31 Merge commit '5f638f55536def0d88b970d1018a465a238e55f4' into ximinez/vault-test
* commit '5f638f55536def0d88b970d1018a465a238e55f4':
  chore: Set ColumnLimit to 120 in clang-format (6288)
2026-01-28 18:07:23 -05:00
Ed Hennis
abfef33493 Merge commit '92046785d1fea5f9efe5a770d636792ea6cab78b' into ximinez/vault-test
* commit '92046785d1fea5f9efe5a770d636792ea6cab78b':
  test: Fix the `xrpl.net` unit test using async read (6241)
  ci: Upload Conan recipes for develop, release candidates, and releases (6286)
  fix: Stop embedded tests from hanging on ARM by using `atomic_flag` (6248)
  fix:  Remove DEFAULT fields that change to the default in associateAsset (6259) (6273)
  refactor: Update Boost to 1.90 (6280)
  refactor: clean up uses of `std::source_location` (6272)
  ci: Pass missing sanitizers input to actions (6266)
  ci: Properly propagate Conan credentials (6265)
  ci: Explicitly set version when exporting the Conan recipe (6264)
  ci: Use plus instead of hyphen for Conan recipe version suffix (6261)
  chore: Detect uninitialized variables in CMake files (6247)
  ci: Run on-trigger and on-pr when generate-version is modified (6257)
  refactor: Enforce 15-char limit and simplify labels for thread naming (6212)
  docs: Update Ripple Bug Bounty public key (6258)
  ci: Add missing commit hash to Conan recipe version (6256)
  fix: Include `<functional>` header in `Number.h` (6254)
  ci: Upload Conan recipe for merges into develop and commits to release (6235)
  Limit reply size on `TMGetObjectByHash` queries (6110)
  ci: remove 'master' branch as a trigger (6234)
  Improve ledger_entry lookups for fee, amendments, NUNL, and hashes (5644)
2026-01-28 18:07:13 -05:00
Ed Hennis
cdcc6b6a1a Avoid input interpolation 2026-01-15 12:15:08 -05:00
Ed Hennis
79058660ce Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  ci: Add sanitizers to CI builds (5996)
2026-01-15 12:12:04 -05:00
Ed Hennis
21315d64fd Merge branch 'develop' into ximinez/vault-test 2026-01-15 12:06:14 -04:00
Ed Hennis
a0a8a15ea7 Merge branch 'develop' into ximinez/vault-test 2026-01-13 18:19:23 -04:00
Ed Hennis
339ef7a9b9 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  fix: Update Conan lock file with changed OpenSSL recipe (6211)
  ci: Update actions/images to use cmake 4.2.1 and conan 2.24.0 (6209)
  refactor: Remove unnecessary version number and options in cmake find_package (6169)
2026-01-13 14:28:30 -05:00
Ed Hennis
cb230ea5a1 Merge branch 'develop' into ximinez/vault-test 2026-01-12 14:52:29 -04:00
Ed Hennis
09912f7da2 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  fix: Inner batch transactions never have valid signatures (6069)
  chore: Change `/Zi` to `/Z7` for ccache, remove debug symbols in CI (6198)
  VaultClawback: Burn shares of an empty vault (6120)
  fix: Truncate thread name to 15 chars on Linux (5758)
  docs: Fix minor spelling issues in comments (6194)
2026-01-10 23:55:20 -05:00
Ed Hennis
5251673b86 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  ci: Use updated prepare-runner in actions and worfklows (6188)
2026-01-08 16:06:35 -05:00
Ed Hennis
33bda40b59 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  refactor: Fix typos, enable cspell pre-commit (5719)
  fix: Reorder Batch Preflight Errors (6176)
  refactor: Remove unused credentials signature hash prefix (6186)
  refactor: Fix spelling issues in all variables/functions (6184)
  refactor: Fix spelling issues in private/local variables and functions (6182)
  refactor: Fix typos in comments, configure cspell (6164)
  ci: Move variable into right place (6179)
  ci: Use ccache to cache build objects for speeding up building (6104)
2026-01-08 12:04:45 -05:00
Ed Hennis
bd35dee693 Merge branch 'develop' into ximinez/vault-test 2026-01-06 14:02:29 -05:00
Ed Hennis
8da0e34746 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  ci: Remove superfluous build directory creation (6159)
2025-12-22 17:40:26 -05:00
Ed Hennis
642eff03c3 Merge branch 'develop' into ximinez/vault-test 2025-12-18 20:00:04 -05:00
Ed Hennis
82d25b4bbd Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  ci: Update shared actions (6147)
  chore: Fix some typos in comments (6082)
2025-12-12 20:35:24 -05:00
Ed Hennis
9bd8e516df Fix formatting 2025-12-12 14:00:12 -05:00
Ed Hennis
8ee703ed05 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  refactor: Rename `ripple` namespace to `xrpl` (5982)
  refactor: Move JobQueue and related classes into xrpl.core module (6121)
  refactor: Rename `rippled` binary to `xrpld` (5983)
  refactor: rename info() to header() (6138)
  refactor: rename `LedgerInfo` to `LedgerHeader` (6136)
  refactor: clean up `RPCHelpers` (5684)
  chore: Fix docs readme and cmake (6122)
  chore: Clean up .gitignore and .gitattributes (6001)
  chore: Use updated secp256k1 recipe (6118)
2025-12-11 16:05:27 -05:00
Ed Hennis
3427b2db16 Merge branch 'develop' into ximinez/vault-test 2025-12-05 21:13:21 -05:00
Ed Hennis
a5de779453 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  Implement Lending Protocol (unsupported) (5270)
2025-12-02 18:40:55 -05:00
Ed Hennis
e9609e0078 Merge branch 'develop' into ximinez/vault-test 2025-12-01 14:40:57 -05:00
Ed Hennis
933e645f85 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  refactor: Replaces ed25519-donna source by Conan package (6088)
  chore: Add black pre-commit hook (6086)
  chore: Make conan lockfile generation commands into a script (6085)
  chore: Update lockfile (6083)
  docs: Update instructions how to (re)generate conan.lock file (6070)
2025-11-28 15:51:15 -05:00
Ed Hennis
7f139d8474 Merge branch 'develop' into ximinez/vault-test 2025-11-26 00:25:30 -05:00
Ed Hennis
3bcf656446 Merge branch 'develop' into ximinez/vault-test 2025-11-25 14:55:19 -05:00
Ed Hennis
5d6ab7e970 Merge branch 'develop' into ximinez/vault-test 2025-11-24 21:49:23 -05:00
Ed Hennis
33f5017c55 Merge branch 'develop' into ximinez/vault-test 2025-11-24 21:30:34 -05:00
Ed Hennis
26ca6c1828 Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  chore: Clean up comment in NetworkOps_test.cpp (6066)
  refactor: Retire DisallowIncoming amendment (6045)
  refactor: Retire Checks amendment (6055)
  ci: Only upload artifacts in XRPLF repo owner (6060)
  fix: Set correct index for limit in `book_offers` CLI (6043)
  Fix: Perform array size check (6030)
2025-11-21 14:33:40 -05:00
Ed Hennis
768049c076 Merge branch 'develop' into ximinez/vault-test 2025-11-18 22:51:17 -05:00
Ed Hennis
58e8f5c032 Merge branch 'develop' into ximinez/vault-test 2025-11-15 03:08:53 -05:00
Ed Hennis
4e3cb34bb5 Merge branch 'develop' into ximinez/vault-test 2025-11-13 12:19:54 -05:00
Ed Hennis
957f4b15eb Merge remote-tracking branch 'XRPLF/develop' into ximinez/vault-test
* XRPLF/develop:
  chore: Set version 3.1.0-b0 (5986)
  ci: Clean workspace on Windows self-hosted runners (6024)
  docs: fix spelling in comments (6002)
  fix: floating point representation errors in vault (5997)
  ci: Specify bash as the default shell in workflows (6021)
  refactor: Add `XRPL_RETIRE_FIX` and `XRPL_RETIRE_FEATURE` macros (6014)
  refactor: Retire DepositPreAuth and DepositAuth amendments (5978)
  chore: Move running of unit tests out of coverage target (6018)
  refactor: Retire PayChanRecipientOwnerDir amendment (5946)
2025-11-12 14:16:09 -05:00
Ed Hennis
bae5a9057f Fix formatting 2025-11-10 19:53:35 -05:00
Ed Hennis
330728eb2d Remove the cmake UNIT_TEST_REFERENCE_FEE setting
- Replaced by --unittest-fee runtime param
2025-11-10 19:53:35 -05:00
Ed Hennis
7dcc839d98 Fix tests when the runner isn't available for the referencefee 2025-11-10 19:53:35 -05:00
Ed Hennis
18a62f4b27 Add command line unittest-fee 2025-11-10 19:53:35 -05:00
323 changed files with 1753 additions and 1475 deletions

View File

@@ -32,6 +32,14 @@ libxrpl.server > xrpl.server
libxrpl.shamap > xrpl.basics
libxrpl.shamap > xrpl.protocol
libxrpl.shamap > xrpl.shamap
libxrpl.tx > xrpl.basics
libxrpl.tx > xrpl.conditions
libxrpl.tx > xrpl.core
libxrpl.tx > xrpl.json
libxrpl.tx > xrpl.ledger
libxrpl.tx > xrpl.protocol
libxrpl.tx > xrpl.server
libxrpl.tx > xrpl.tx
test.app > test.jtx
test.app > test.rpc
test.app > test.toplevel
@@ -49,6 +57,7 @@ test.app > xrpl.protocol
test.app > xrpl.rdb
test.app > xrpl.resource
test.app > xrpl.server
test.app > xrpl.tx
test.basics > test.jtx
test.basics > test.unit_test
test.basics > xrpl.basics
@@ -67,6 +76,7 @@ test.consensus > xrpld.app
test.consensus > xrpld.consensus
test.consensus > xrpl.json
test.consensus > xrpl.ledger
test.consensus > xrpl.tx
test.core > test.jtx
test.core > test.toplevel
test.core > test.unit_test
@@ -83,6 +93,7 @@ test.csf > xrpl.protocol
test.json > test.jtx
test.json > xrpl.json
test.jtx > xrpl.basics
test.jtx > xrpl.core
test.jtx > xrpld.app
test.jtx > xrpld.core
test.jtx > xrpld.rpc
@@ -92,6 +103,7 @@ test.jtx > xrpl.net
test.jtx > xrpl.protocol
test.jtx > xrpl.resource
test.jtx > xrpl.server
test.jtx > xrpl.tx
test.ledger > test.jtx
test.ledger > test.toplevel
test.ledger > xrpl.basics
@@ -137,9 +149,11 @@ test.rpc > xrpld.core
test.rpc > xrpld.overlay
test.rpc > xrpld.rpc
test.rpc > xrpl.json
test.rpc > xrpl.ledger
test.rpc > xrpl.protocol
test.rpc > xrpl.resource
test.rpc > xrpl.server
test.rpc > xrpl.tx
test.server > test.jtx
test.server > test.toplevel
test.server > test.unit_test
@@ -170,6 +184,7 @@ xrpl.json > xrpl.basics
xrpl.ledger > xrpl.basics
xrpl.ledger > xrpl.protocol
xrpl.ledger > xrpl.server
xrpl.ledger > xrpl.shamap
xrpl.net > xrpl.basics
xrpl.nodestore > xrpl.basics
xrpl.nodestore > xrpl.protocol
@@ -191,9 +206,12 @@ xrpl.server > xrpl.shamap
xrpl.shamap > xrpl.basics
xrpl.shamap > xrpl.nodestore
xrpl.shamap > xrpl.protocol
xrpl.tx > xrpl.basics
xrpl.tx > xrpl.core
xrpl.tx > xrpl.ledger
xrpl.tx > xrpl.protocol
xrpld.app > test.unit_test
xrpld.app > xrpl.basics
xrpld.app > xrpl.conditions
xrpld.app > xrpl.core
xrpld.app > xrpld.consensus
xrpld.app > xrpld.core
@@ -206,6 +224,7 @@ xrpld.app > xrpl.rdb
xrpld.app > xrpl.resource
xrpld.app > xrpl.server
xrpld.app > xrpl.shamap
xrpld.app > xrpl.tx
xrpld.consensus > xrpl.basics
xrpld.consensus > xrpl.json
xrpld.consensus > xrpl.protocol
@@ -224,6 +243,7 @@ xrpld.overlay > xrpl.protocol
xrpld.overlay > xrpl.rdb
xrpld.overlay > xrpl.resource
xrpld.overlay > xrpl.server
xrpld.overlay > xrpl.tx
xrpld.peerfinder > xrpl.basics
xrpld.peerfinder > xrpld.core
xrpld.peerfinder > xrpl.protocol
@@ -243,4 +263,5 @@ xrpld.rpc > xrpl.protocol
xrpld.rpc > xrpl.rdb
xrpld.rpc > xrpl.resource
xrpld.rpc > xrpl.server
xrpld.rpc > xrpl.tx
xrpld.shamap > xrpl.shamap

View File

@@ -40,6 +40,7 @@ def generate_strategy_matrix(all: bool, config: Config) -> list:
# The default CMake target is 'all' for Linux and MacOS and 'install'
# for Windows, but it can get overridden for certain configurations.
cmake_target = "install" if os["distro_name"] == "windows" else "all"
unittest_args = ""
# We build and test all configurations by default, except for Windows in
# Debug, because it is too slow, as well as when code coverage is
@@ -67,7 +68,7 @@ def generate_strategy_matrix(all: bool, config: Config) -> list:
and build_type == "Release"
and architecture["platform"] == "linux/amd64"
):
cmake_args = f"-DUNIT_TEST_REFERENCE_FEE=500 {cmake_args}"
unittest_args = f"{unittest_args} --unittest-fee=500"
skip = False
if (
f"{os['compiler_name']}-{os['compiler_version']}" == "gcc-15"
@@ -87,7 +88,7 @@ def generate_strategy_matrix(all: bool, config: Config) -> list:
and build_type == "Release"
and architecture["platform"] == "linux/amd64"
):
cmake_args = f"-DUNIT_TEST_REFERENCE_FEE=1000 {cmake_args}"
unittest_args = f"{unittest_args} --unittest-fee=1000"
skip = False
if (
f"{os['compiler_name']}-{os['compiler_version']}" == "clang-20"
@@ -245,6 +246,7 @@ def generate_strategy_matrix(all: bool, config: Config) -> list:
{
"config_name": config_name + "-asan-ubsan",
"cmake_args": cmake_args,
"unittest_args": unittest_args,
"cmake_target": cmake_target,
"build_only": build_only,
"build_type": build_type,
@@ -260,6 +262,7 @@ def generate_strategy_matrix(all: bool, config: Config) -> list:
{
"config_name": config_name + "-tsan-ubsan",
"cmake_args": cmake_args,
"unittest_args": unittest_args,
"cmake_target": cmake_target,
"build_only": build_only,
"build_type": build_type,
@@ -273,6 +276,7 @@ def generate_strategy_matrix(all: bool, config: Config) -> list:
{
"config_name": config_name,
"cmake_args": cmake_args,
"unittest_args": unittest_args,
"cmake_target": cmake_target,
"build_only": build_only,
"build_type": build_type,

View File

@@ -25,6 +25,12 @@ on:
type: string
default: ""
unittest_args:
description: "Additional arguments to pass to rippled when running tests"
required: false
type: string
default: ""
cmake_target:
description: "The CMake target to build."
required: true
@@ -228,8 +234,10 @@ jobs:
working-directory: ${{ runner.os == 'Windows' && format('{0}/{1}', env.BUILD_DIR, inputs.build_type) || env.BUILD_DIR }}
env:
BUILD_NPROC: ${{ steps.nproc.outputs.nproc }}
UNITTEST_ARGS: ${{ inputs.unittest_args }}
run: |
./xrpld --unittest --unittest-jobs "${BUILD_NPROC}"
./xrpld --unittest --unittest-jobs "${BUILD_NPROC}" \
${UNITTEST_ARGS}
- name: Debug failure (Linux)
if: ${{ failure() && runner.os == 'Linux' && !inputs.build_only }}

View File

@@ -53,6 +53,7 @@ jobs:
build_type: ${{ matrix.build_type }}
ccache_enabled: ${{ inputs.ccache_enabled }}
cmake_args: ${{ matrix.cmake_args }}
unittest_args: ${{ matrix.unittest_args }}
cmake_target: ${{ matrix.cmake_target }}
runs_on: ${{ toJSON(matrix.architecture.runner) }}
image: ${{ contains(matrix.architecture.platform, 'linux') && format('ghcr.io/xrplf/ci/{0}-{1}:{2}-{3}-sha-{4}', matrix.os.distro_name, matrix.os.distro_version, matrix.os.compiler_name, matrix.os.compiler_version, matrix.os.image_sha) || '' }}

3
.gitignore vendored
View File

@@ -71,3 +71,6 @@ DerivedData
/.augment
/.claude
/CLAUDE.md
# clangd cache
/.cache

View File

@@ -20,7 +20,7 @@ repos:
args: [--assume-in-merge]
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: 7d85583be209cb547946c82fbe51f4bc5dd1d017 # frozen: v18.1.8
rev: 75ca4ad908dc4a99f57921f29b7e6c1521e10b26 # frozen: v21.1.8
hooks:
- id: clang-format
args: [--style=file]

View File

@@ -219,7 +219,7 @@ coherent rather than a set of _thou shalt not_ commandments.
## Formatting
All code must conform to `clang-format` version 18,
All code must conform to `clang-format` version 21,
according to the settings in [`.clang-format`](./.clang-format),
unless the result would be unreasonably difficult to read or maintain.
To demarcate lines that should be left as-is, surround them with comments like

View File

@@ -109,8 +109,12 @@ target_link_libraries(
xrpl.libxrpl.protocol
xrpl.libxrpl.rdb
xrpl.libxrpl.server
xrpl.libxrpl.shamap
xrpl.libxrpl.conditions)
add_module(xrpl tx)
target_link_libraries(xrpl.libxrpl.tx PUBLIC xrpl.libxrpl.ledger)
add_library(xrpl.libxrpl)
set_target_properties(xrpl.libxrpl PROPERTIES OUTPUT_NAME xrpl)
@@ -135,7 +139,8 @@ target_link_modules(
rdb
resource
server
shamap)
shamap
tx)
# All headers in libxrpl are in modules.
# Uncomment this stanza if you have not yet moved new headers into a module.
@@ -150,7 +155,6 @@ if (xrpld)
add_executable(xrpld)
if (tests)
target_compile_definitions(xrpld PUBLIC ENABLE_TESTS)
target_compile_definitions(xrpld PRIVATE UNIT_TEST_REFERENCE_FEE=${UNIT_TEST_REFERENCE_FEE})
endif ()
target_include_directories(xrpld PRIVATE $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src>)

View File

@@ -32,6 +32,7 @@ install(TARGETS common
xrpl.libxrpl.resource
xrpl.libxrpl.server
xrpl.libxrpl.shamap
xrpl.libxrpl.tx
antithesis-sdk-cpp
EXPORT XrplExports
LIBRARY DESTINATION lib

View File

@@ -23,12 +23,6 @@ option(assert "Enables asserts, even in release builds" OFF)
option(xrpld "Build xrpld" ON)
option(tests "Build tests" ON)
if (tests)
# This setting allows making a separate workflow to test fees other than default 10
if (NOT UNIT_TEST_REFERENCE_FEE)
set(UNIT_TEST_REFERENCE_FEE "10" CACHE STRING "")
endif ()
endif ()
option(unity "Creates a build using UNITY support in cmake." OFF)
if (unity)

View File

@@ -208,7 +208,8 @@ SharedIntrusive<T>::operator->() const noexcept
}
template <class T>
SharedIntrusive<T>::operator bool() const noexcept
SharedIntrusive<T>::
operator bool() const noexcept
{
return bool(unsafeGetRawPtr());
}
@@ -503,7 +504,8 @@ SharedWeakUnion<T>::getStrong() const
}
template <class T>
SharedWeakUnion<T>::operator bool() const noexcept
SharedWeakUnion<T>::
operator bool() const noexcept
{
return bool(get());
}

View File

@@ -63,7 +63,8 @@ SharedWeakCachePointer<T>::getStrong() const
}
template <class T>
SharedWeakCachePointer<T>::operator bool() const noexcept
SharedWeakCachePointer<T>::
operator bool() const noexcept
{
return !!std::get_if<std::shared_ptr<T>>(&combo_);
}

View File

@@ -215,7 +215,7 @@ public:
// clang-format off
if (!buf) [[unlikely]]
return nullptr;
// clang-format on
// clang-format on
#if BOOST_OS_LINUX
// When allocating large blocks, attempt to leverage Linux's

View File

@@ -9,6 +9,7 @@
#include <boost/assert.hpp>
#include <mutex>
#include <optional>
#include <string>
namespace beast {
@@ -22,6 +23,7 @@ namespace unit_test {
class runner
{
std::string arg_;
std::optional<std::int64_t> referenceFee_;
bool default_ = false;
bool failed_ = false;
bool cond_ = false;
@@ -54,6 +56,24 @@ public:
return arg_;
}
/** Set the reference fee (in drops) for tests.
If provided, this value is used in every suite that
does not override it.
*/
void
referenceFee(std::int64_t fee)
{
referenceFee_ = fee;
}
/** Returns the reference fee, if any. */
std::optional<std::int64_t> const&
referenceFee() const
{
return referenceFee_;
}
/** Run the specified suite.
@return `true` if any conditions failed.
*/

View File

@@ -278,6 +278,16 @@ public:
return runner_->arg();
}
/** Return the reference fee associated with the runner. */
std::optional<std::int64_t>
referenceFee() const
{
assert(runner_);
if (!runner_)
return {};
return runner_->referenceFee();
}
// DEPRECATED
// @return `true` if the test condition indicates success(a false value)
template <class Condition, class String>

View File

@@ -0,0 +1,33 @@
#pragma once
#include <cstdint>
namespace xrpl {
/** Service that provides access to the network ID.
This service provides read-only access to the network ID configured
for this server. The network ID identifies which network (mainnet,
testnet, devnet, or custom network) this server is configured to
connect to.
Well-known network IDs:
- 0: Mainnet
- 1: Testnet
- 2: Devnet
- 1025+: Custom networks (require NetworkID field in transactions)
*/
class NetworkIDService
{
public:
virtual ~NetworkIDService() = default;
/** Get the configured network ID
*
* @return The network ID this server is configured for
*/
virtual std::uint32_t
getNetworkID() const noexcept = 0;
};
} // namespace xrpl

View File

@@ -41,6 +41,7 @@ class LoadFeeTrack;
class LoadManager;
class ManifestCache;
class NetworkOPs;
class NetworkIDService;
class OpenLedger;
class OrderBookDB;
class Overlay;
@@ -99,6 +100,9 @@ public:
virtual CachedSLEs&
cachedSLEs() = 0;
virtual NetworkIDService&
getNetworkIDService() = 0;
// Protocol and validation services
virtual AmendmentTable&
getAmendmentTable() = 0;

View File

@@ -1,17 +1,18 @@
#pragma once
#include <xrpld/app/ledger/Ledger.h>
#include <xrpld/core/ConfigSections.h>
#include <xrpl/core/ServiceRegistry.h>
#include <xrpl/ledger/ReadView.h>
#include <xrpl/ledger/View.h>
#include <xrpl/protocol/Feature.h>
#include <xrpl/protocol/Protocol.h>
#include <xrpl/protocol/STValidation.h>
#include <xrpl/shamap/SHAMap.h>
#include <optional>
namespace xrpl {
class ServiceRegistry;
/** The amendment table stores the list of enabled and potential amendments.
Individuals amendments are voted on by validators during the consensus
process.

View File

@@ -296,7 +296,7 @@ public:
friend FeatureBitset
operator^(FeatureBitset const& lhs, uint256 const& rhs)
{
return lhs ^ FeatureBitset { rhs };
return lhs ^ FeatureBitset{rhs};
}
friend FeatureBitset

View File

@@ -110,7 +110,8 @@ IOUAmount::operator=(beast::Zero)
return *this;
}
inline IOUAmount::operator Number() const
inline IOUAmount::
operator Number() const
{
return Number{mantissa_, exponent_};
}
@@ -140,7 +141,8 @@ IOUAmount::operator<(IOUAmount const& other) const
return Number{*this} < Number{other};
}
inline IOUAmount::operator bool() const noexcept
inline IOUAmount::
operator bool() const noexcept
{
return mantissa_ != 0;
}

View File

@@ -93,7 +93,8 @@ MPTAmount::operator=(beast::Zero)
}
/** Returns true if the amount is not zero */
constexpr MPTAmount::operator bool() const noexcept
constexpr MPTAmount::
operator bool() const noexcept
{
return value_ != 0;
}

View File

@@ -107,7 +107,7 @@ struct MultiApiJson
// unsigned int version, extra arguments
template <typename Json, typename Version, typename... Args, typename Fn>
requires(!some_integral_constant<Version>) && std::convertible_to<Version, unsigned> &&
std::same_as<std::remove_cvref_t<Json>, MultiApiJson>
std::same_as<std::remove_cvref_t<Json>, MultiApiJson>
auto
operator()(Json& json, Version version, Fn fn, Args&&... args) const
-> std::invoke_result_t<Fn, decltype(json.val[0]), Version, Args&&...>
@@ -122,7 +122,7 @@ struct MultiApiJson
// unsigned int version, Json only
template <typename Json, typename Version, typename Fn>
requires(!some_integral_constant<Version>) && std::convertible_to<Version, unsigned> &&
std::same_as<std::remove_cvref_t<Json>, MultiApiJson>
std::same_as<std::remove_cvref_t<Json>, MultiApiJson>
auto
operator()(Json& json, Version version, Fn fn) const -> std::invoke_result_t<Fn, decltype(json.val[0])>
{

View File

@@ -253,6 +253,16 @@ std::uint8_t constexpr maxAssetCheckDepth = 5;
/** A ledger index. */
using LedgerIndex = std::uint32_t;
std::uint32_t constexpr FLAG_LEDGER_INTERVAL = 256;
/** Returns true if the given ledgerIndex is a voting ledgerIndex */
bool
isVotingLedger(LedgerIndex seq);
/** Returns true if the given ledgerIndex is a flag ledgerIndex */
bool
isFlagLedger(LedgerIndex seq);
/** A transaction identifier.
The value is computed as the hash of the
canonicalized, serialized transaction object.

View File

@@ -480,12 +480,14 @@ STAmount::zeroed() const
return STAmount(mAsset);
}
inline STAmount::operator bool() const noexcept
inline STAmount::
operator bool() const noexcept
{
return *this != beast::zero;
}
inline STAmount::operator Number() const
inline STAmount::
operator Number() const
{
if (native())
return xrp();

View File

@@ -169,7 +169,8 @@ STBitString<Bits>::value() const
}
template <int Bits>
STBitString<Bits>::operator value_type() const
STBitString<Bits>::
operator value_type() const
{
return value_;
}

View File

@@ -134,7 +134,8 @@ STInteger<Integer>::setValue(Integer v)
}
template <typename Integer>
inline STInteger<Integer>::operator Integer() const
inline STInteger<Integer>::
operator Integer() const
{
return value_;
}

View File

@@ -147,9 +147,12 @@ public:
int
getCount() const;
bool setFlag(std::uint32_t);
bool clearFlag(std::uint32_t);
bool isFlag(std::uint32_t) const;
bool
setFlag(std::uint32_t);
bool
clearFlag(std::uint32_t);
bool
isFlag(std::uint32_t) const;
std::uint32_t
getFlags() const;
@@ -799,7 +802,8 @@ STObject::ValueProxy<T>::operator-=(U const& u)
}
template <class T>
STObject::ValueProxy<T>::operator value_type() const
STObject::ValueProxy<T>::
operator value_type() const
{
return this->value();
}
@@ -812,13 +816,15 @@ STObject::ValueProxy<T>::ValueProxy(STObject* st, TypedField<T> const* f) : Prox
//------------------------------------------------------------------------------
template <class T>
STObject::OptionalProxy<T>::operator bool() const noexcept
STObject::OptionalProxy<T>::
operator bool() const noexcept
{
return engaged();
}
template <class T>
STObject::OptionalProxy<T>::operator typename STObject::OptionalProxy<T>::optional_type() const
STObject::OptionalProxy<T>::
operator typename STObject::OptionalProxy<T>::optional_type() const
{
return optional_value();
}

View File

@@ -135,7 +135,8 @@ STVector256::setValue(STVector256 const& v)
}
/** Retrieve a copy of the vector we contain */
inline STVector256::operator std::vector<uint256>() const
inline STVector256::
operator std::vector<uint256>() const
{
return mValue;
}

View File

@@ -484,60 +484,54 @@ public:
// Only enabled if both arguments return int if TERtiInt is called with them.
template <typename L, typename R>
constexpr auto
operator==(L const& lhs, R const& rhs)
-> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
operator==(L const& lhs, R const& rhs) -> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
{
return TERtoInt(lhs) == TERtoInt(rhs);
}
template <typename L, typename R>
constexpr auto
operator!=(L const& lhs, R const& rhs)
-> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
operator!=(L const& lhs, R const& rhs) -> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
{
return TERtoInt(lhs) != TERtoInt(rhs);
}
template <typename L, typename R>
constexpr auto
operator<(L const& lhs, R const& rhs)
-> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
operator<(L const& lhs, R const& rhs) -> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
{
return TERtoInt(lhs) < TERtoInt(rhs);
}
template <typename L, typename R>
constexpr auto
operator<=(L const& lhs, R const& rhs)
-> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
operator<=(L const& lhs, R const& rhs) -> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
{
return TERtoInt(lhs) <= TERtoInt(rhs);
}
template <typename L, typename R>
constexpr auto
operator>(L const& lhs, R const& rhs)
-> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
operator>(L const& lhs, R const& rhs) -> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
{
return TERtoInt(lhs) > TERtoInt(rhs);
}
template <typename L, typename R>
constexpr auto
operator>=(L const& lhs, R const& rhs)
-> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
operator>=(L const& lhs, R const& rhs) -> std::enable_if_t<
std::is_same<decltype(TERtoInt(lhs)), int>::value && std::is_same<decltype(TERtoInt(rhs)), int>::value,
bool>
{
return TERtoInt(lhs) >= TERtoInt(rhs);
}

View File

@@ -8,11 +8,11 @@
* To ease maintenance, you may replace any unneeded values with "..."
* e.g. #define TRANSACTION(tag, value, name, ...)
*
* You must define a transactor class in the `ripple` namespace named `name`,
* You must define a transactor class in the `xrpl` namespace named `name`,
* and include its header alongside the TRANSACTOR definition using this
* format:
* #if TRANSACTION_INCLUDE
* # include <xrpld/app/tx/detail/HEADER.h>
* # include <xrpl/tx/transactors/HEADER.h>
* #endif
*
* The `privileges` parameter of the TRANSACTION macro is a bitfield
@@ -22,7 +22,7 @@
/** This transaction type executes a payment. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/Payment.h>
# include <xrpl/tx/transactors/Payment.h>
#endif
TRANSACTION(ttPAYMENT, 0, Payment,
Delegation::delegable,
@@ -42,7 +42,7 @@ TRANSACTION(ttPAYMENT, 0, Payment,
/** This transaction type creates an escrow object. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/Escrow.h>
# include <xrpl/tx/transactors/Escrow.h>
#endif
TRANSACTION(ttESCROW_CREATE, 1, EscrowCreate,
Delegation::delegable,
@@ -73,7 +73,7 @@ TRANSACTION(ttESCROW_FINISH, 2, EscrowFinish,
/** This transaction type adjusts various account settings. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/SetAccount.h>
# include <xrpl/tx/transactors/SetAccount.h>
#endif
TRANSACTION(ttACCOUNT_SET, 3, AccountSet,
Delegation::notDelegable,
@@ -94,7 +94,7 @@ TRANSACTION(ttACCOUNT_SET, 3, AccountSet,
/** This transaction type cancels an existing escrow. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/Escrow.h>
# include <xrpl/tx/transactors/Escrow.h>
#endif
TRANSACTION(ttESCROW_CANCEL, 4, EscrowCancel,
Delegation::delegable,
@@ -107,7 +107,7 @@ TRANSACTION(ttESCROW_CANCEL, 4, EscrowCancel,
/** This transaction type sets or clears an account's "regular key". */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/SetRegularKey.h>
# include <xrpl/tx/transactors/SetRegularKey.h>
#endif
TRANSACTION(ttREGULAR_KEY_SET, 5, SetRegularKey,
Delegation::notDelegable,
@@ -121,7 +121,7 @@ TRANSACTION(ttREGULAR_KEY_SET, 5, SetRegularKey,
/** This transaction type creates an offer to trade one asset for another. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/CreateOffer.h>
# include <xrpl/tx/transactors/Offer/CreateOffer.h>
#endif
TRANSACTION(ttOFFER_CREATE, 7, OfferCreate,
Delegation::delegable,
@@ -137,7 +137,7 @@ TRANSACTION(ttOFFER_CREATE, 7, OfferCreate,
/** This transaction type cancels existing offers to trade one asset for another. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/CancelOffer.h>
# include <xrpl/tx/transactors/Offer/CancelOffer.h>
#endif
TRANSACTION(ttOFFER_CANCEL, 8, OfferCancel,
Delegation::delegable,
@@ -151,7 +151,7 @@ TRANSACTION(ttOFFER_CANCEL, 8, OfferCancel,
/** This transaction type creates a new set of tickets. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/CreateTicket.h>
# include <xrpl/tx/transactors/CreateTicket.h>
#endif
TRANSACTION(ttTICKET_CREATE, 10, TicketCreate,
Delegation::delegable,
@@ -167,7 +167,7 @@ TRANSACTION(ttTICKET_CREATE, 10, TicketCreate,
// The SignerEntries are optional because a SignerList is deleted by
// setting the SignerQuorum to zero and omitting SignerEntries.
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/SetSignerList.h>
# include <xrpl/tx/transactors/SetSignerList.h>
#endif
TRANSACTION(ttSIGNER_LIST_SET, 12, SignerListSet,
Delegation::notDelegable,
@@ -180,7 +180,7 @@ TRANSACTION(ttSIGNER_LIST_SET, 12, SignerListSet,
/** This transaction type creates a new unidirectional XRP payment channel. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/PayChan.h>
# include <xrpl/tx/transactors/PayChan.h>
#endif
TRANSACTION(ttPAYCHAN_CREATE, 13, PaymentChannelCreate,
Delegation::delegable,
@@ -222,7 +222,7 @@ TRANSACTION(ttPAYCHAN_CLAIM, 15, PaymentChannelClaim,
/** This transaction type creates a new check. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/CreateCheck.h>
# include <xrpl/tx/transactors/Check/CreateCheck.h>
#endif
TRANSACTION(ttCHECK_CREATE, 16, CheckCreate,
Delegation::delegable,
@@ -238,7 +238,7 @@ TRANSACTION(ttCHECK_CREATE, 16, CheckCreate,
/** This transaction type cashes an existing check. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/CashCheck.h>
# include <xrpl/tx/transactors/Check/CashCheck.h>
#endif
TRANSACTION(ttCHECK_CASH, 17, CheckCash,
Delegation::delegable,
@@ -252,7 +252,7 @@ TRANSACTION(ttCHECK_CASH, 17, CheckCash,
/** This transaction type cancels an existing check. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/CancelCheck.h>
# include <xrpl/tx/transactors/Check/CancelCheck.h>
#endif
TRANSACTION(ttCHECK_CANCEL, 18, CheckCancel,
Delegation::delegable,
@@ -264,7 +264,7 @@ TRANSACTION(ttCHECK_CANCEL, 18, CheckCancel,
/** This transaction type grants or revokes authorization to transfer funds. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/DepositPreauth.h>
# include <xrpl/tx/transactors/DepositPreauth.h>
#endif
TRANSACTION(ttDEPOSIT_PREAUTH, 19, DepositPreauth,
Delegation::delegable,
@@ -279,7 +279,7 @@ TRANSACTION(ttDEPOSIT_PREAUTH, 19, DepositPreauth,
/** This transaction type modifies a trustline between two accounts. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/SetTrust.h>
# include <xrpl/tx/transactors/SetTrust.h>
#endif
TRANSACTION(ttTRUST_SET, 20, TrustSet,
Delegation::delegable,
@@ -293,7 +293,7 @@ TRANSACTION(ttTRUST_SET, 20, TrustSet,
/** This transaction type deletes an existing account. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/DeleteAccount.h>
# include <xrpl/tx/transactors/DeleteAccount.h>
#endif
TRANSACTION(ttACCOUNT_DELETE, 21, AccountDelete,
Delegation::notDelegable,
@@ -309,7 +309,7 @@ TRANSACTION(ttACCOUNT_DELETE, 21, AccountDelete,
/** This transaction mints a new NFT. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/NFTokenMint.h>
# include <xrpl/tx/transactors/NFT/NFTokenMint.h>
#endif
TRANSACTION(ttNFTOKEN_MINT, 25, NFTokenMint,
Delegation::delegable,
@@ -327,7 +327,7 @@ TRANSACTION(ttNFTOKEN_MINT, 25, NFTokenMint,
/** This transaction burns (i.e. destroys) an existing NFT. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/NFTokenBurn.h>
# include <xrpl/tx/transactors/NFT/NFTokenBurn.h>
#endif
TRANSACTION(ttNFTOKEN_BURN, 26, NFTokenBurn,
Delegation::delegable,
@@ -340,7 +340,7 @@ TRANSACTION(ttNFTOKEN_BURN, 26, NFTokenBurn,
/** This transaction creates a new offer to buy or sell an NFT. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/NFTokenCreateOffer.h>
# include <xrpl/tx/transactors/NFT/NFTokenCreateOffer.h>
#endif
TRANSACTION(ttNFTOKEN_CREATE_OFFER, 27, NFTokenCreateOffer,
Delegation::delegable,
@@ -356,7 +356,7 @@ TRANSACTION(ttNFTOKEN_CREATE_OFFER, 27, NFTokenCreateOffer,
/** This transaction cancels an existing offer to buy or sell an existing NFT. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/NFTokenCancelOffer.h>
# include <xrpl/tx/transactors/NFT/NFTokenCancelOffer.h>
#endif
TRANSACTION(ttNFTOKEN_CANCEL_OFFER, 28, NFTokenCancelOffer,
Delegation::delegable,
@@ -368,7 +368,7 @@ TRANSACTION(ttNFTOKEN_CANCEL_OFFER, 28, NFTokenCancelOffer,
/** This transaction accepts an existing offer to buy or sell an existing NFT. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/NFTokenAcceptOffer.h>
# include <xrpl/tx/transactors/NFT/NFTokenAcceptOffer.h>
#endif
TRANSACTION(ttNFTOKEN_ACCEPT_OFFER, 29, NFTokenAcceptOffer,
Delegation::delegable,
@@ -382,7 +382,7 @@ TRANSACTION(ttNFTOKEN_ACCEPT_OFFER, 29, NFTokenAcceptOffer,
/** This transaction claws back issued tokens. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/Clawback.h>
# include <xrpl/tx/transactors/Clawback.h>
#endif
TRANSACTION(ttCLAWBACK, 30, Clawback,
Delegation::delegable,
@@ -395,7 +395,7 @@ TRANSACTION(ttCLAWBACK, 30, Clawback,
/** This transaction claws back tokens from an AMM pool. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/AMMClawback.h>
# include <xrpl/tx/transactors/AMM/AMMClawback.h>
#endif
TRANSACTION(ttAMM_CLAWBACK, 31, AMMClawback,
Delegation::delegable,
@@ -410,7 +410,7 @@ TRANSACTION(ttAMM_CLAWBACK, 31, AMMClawback,
/** This transaction type creates an AMM instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/AMMCreate.h>
# include <xrpl/tx/transactors/AMM/AMMCreate.h>
#endif
TRANSACTION(ttAMM_CREATE, 35, AMMCreate,
Delegation::delegable,
@@ -424,7 +424,7 @@ TRANSACTION(ttAMM_CREATE, 35, AMMCreate,
/** This transaction type deposits into an AMM instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/AMMDeposit.h>
# include <xrpl/tx/transactors/AMM/AMMDeposit.h>
#endif
TRANSACTION(ttAMM_DEPOSIT, 36, AMMDeposit,
Delegation::delegable,
@@ -442,7 +442,7 @@ TRANSACTION(ttAMM_DEPOSIT, 36, AMMDeposit,
/** This transaction type withdraws from an AMM instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/AMMWithdraw.h>
# include <xrpl/tx/transactors/AMM/AMMWithdraw.h>
#endif
TRANSACTION(ttAMM_WITHDRAW, 37, AMMWithdraw,
Delegation::delegable,
@@ -459,7 +459,7 @@ TRANSACTION(ttAMM_WITHDRAW, 37, AMMWithdraw,
/** This transaction type votes for the trading fee */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/AMMVote.h>
# include <xrpl/tx/transactors/AMM/AMMVote.h>
#endif
TRANSACTION(ttAMM_VOTE, 38, AMMVote,
Delegation::delegable,
@@ -473,7 +473,7 @@ TRANSACTION(ttAMM_VOTE, 38, AMMVote,
/** This transaction type bids for the auction slot */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/AMMBid.h>
# include <xrpl/tx/transactors/AMM/AMMBid.h>
#endif
TRANSACTION(ttAMM_BID, 39, AMMBid,
Delegation::delegable,
@@ -489,7 +489,7 @@ TRANSACTION(ttAMM_BID, 39, AMMBid,
/** This transaction type deletes AMM in the empty state */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/AMMDelete.h>
# include <xrpl/tx/transactors/AMM/AMMDelete.h>
#endif
TRANSACTION(ttAMM_DELETE, 40, AMMDelete,
Delegation::delegable,
@@ -502,7 +502,7 @@ TRANSACTION(ttAMM_DELETE, 40, AMMDelete,
/** This transactions creates a crosschain sequence number */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/XChainBridge.h>
# include <xrpl/tx/transactors/XChainBridge.h>
#endif
TRANSACTION(ttXCHAIN_CREATE_CLAIM_ID, 41, XChainCreateClaimID,
Delegation::delegable,
@@ -617,7 +617,7 @@ TRANSACTION(ttXCHAIN_CREATE_BRIDGE, 48, XChainCreateBridge,
/** This transaction type creates or updates a DID */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/DID.h>
# include <xrpl/tx/transactors/DID.h>
#endif
TRANSACTION(ttDID_SET, 49, DIDSet,
Delegation::delegable,
@@ -638,7 +638,7 @@ TRANSACTION(ttDID_DELETE, 50, DIDDelete,
/** This transaction type creates an Oracle instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/SetOracle.h>
# include <xrpl/tx/transactors/SetOracle.h>
#endif
TRANSACTION(ttORACLE_SET, 51, OracleSet,
Delegation::delegable,
@@ -655,7 +655,7 @@ TRANSACTION(ttORACLE_SET, 51, OracleSet,
/** This transaction type deletes an Oracle instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/DeleteOracle.h>
# include <xrpl/tx/transactors/DeleteOracle.h>
#endif
TRANSACTION(ttORACLE_DELETE, 52, OracleDelete,
Delegation::delegable,
@@ -667,7 +667,7 @@ TRANSACTION(ttORACLE_DELETE, 52, OracleDelete,
/** This transaction type fixes a problem in the ledger state */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LedgerStateFix.h>
# include <xrpl/tx/transactors/LedgerStateFix.h>
#endif
TRANSACTION(ttLEDGER_STATE_FIX, 53, LedgerStateFix,
Delegation::delegable,
@@ -680,7 +680,7 @@ TRANSACTION(ttLEDGER_STATE_FIX, 53, LedgerStateFix,
/** This transaction type creates a MPTokensIssuance instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/MPTokenIssuanceCreate.h>
# include <xrpl/tx/transactors/MPT/MPTokenIssuanceCreate.h>
#endif
TRANSACTION(ttMPTOKEN_ISSUANCE_CREATE, 54, MPTokenIssuanceCreate,
Delegation::delegable,
@@ -697,7 +697,7 @@ TRANSACTION(ttMPTOKEN_ISSUANCE_CREATE, 54, MPTokenIssuanceCreate,
/** This transaction type destroys a MPTokensIssuance instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/MPTokenIssuanceDestroy.h>
# include <xrpl/tx/transactors/MPT/MPTokenIssuanceDestroy.h>
#endif
TRANSACTION(ttMPTOKEN_ISSUANCE_DESTROY, 55, MPTokenIssuanceDestroy,
Delegation::delegable,
@@ -709,7 +709,7 @@ TRANSACTION(ttMPTOKEN_ISSUANCE_DESTROY, 55, MPTokenIssuanceDestroy,
/** This transaction type sets flags on a MPTokensIssuance or MPToken instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/MPTokenIssuanceSet.h>
# include <xrpl/tx/transactors/MPT/MPTokenIssuanceSet.h>
#endif
TRANSACTION(ttMPTOKEN_ISSUANCE_SET, 56, MPTokenIssuanceSet,
Delegation::delegable,
@@ -726,7 +726,7 @@ TRANSACTION(ttMPTOKEN_ISSUANCE_SET, 56, MPTokenIssuanceSet,
/** This transaction type authorizes a MPToken instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/MPTokenAuthorize.h>
# include <xrpl/tx/transactors/MPT/MPTokenAuthorize.h>
#endif
TRANSACTION(ttMPTOKEN_AUTHORIZE, 57, MPTokenAuthorize,
Delegation::delegable,
@@ -739,7 +739,7 @@ TRANSACTION(ttMPTOKEN_AUTHORIZE, 57, MPTokenAuthorize,
/** This transaction type create an Credential instance */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/Credentials.h>
# include <xrpl/tx/transactors/Credentials.h>
#endif
TRANSACTION(ttCREDENTIAL_CREATE, 58, CredentialCreate,
Delegation::delegable,
@@ -775,7 +775,7 @@ TRANSACTION(ttCREDENTIAL_DELETE, 60, CredentialDelete,
/** This transaction type modify a NFToken */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/NFTokenModify.h>
# include <xrpl/tx/transactors/NFT/NFTokenModify.h>
#endif
TRANSACTION(ttNFTOKEN_MODIFY, 61, NFTokenModify,
Delegation::delegable,
@@ -789,7 +789,7 @@ TRANSACTION(ttNFTOKEN_MODIFY, 61, NFTokenModify,
/** This transaction type creates or modifies a Permissioned Domain */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/PermissionedDomainSet.h>
# include <xrpl/tx/transactors/PermissionedDomain/PermissionedDomainSet.h>
#endif
TRANSACTION(ttPERMISSIONED_DOMAIN_SET, 62, PermissionedDomainSet,
Delegation::delegable,
@@ -802,7 +802,7 @@ TRANSACTION(ttPERMISSIONED_DOMAIN_SET, 62, PermissionedDomainSet,
/** This transaction type deletes a Permissioned Domain */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/PermissionedDomainDelete.h>
# include <xrpl/tx/transactors/PermissionedDomain/PermissionedDomainDelete.h>
#endif
TRANSACTION(ttPERMISSIONED_DOMAIN_DELETE, 63, PermissionedDomainDelete,
Delegation::delegable,
@@ -814,7 +814,7 @@ TRANSACTION(ttPERMISSIONED_DOMAIN_DELETE, 63, PermissionedDomainDelete,
/** This transaction type delegates authorized account specified permissions */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/DelegateSet.h>
# include <xrpl/tx/transactors/Delegate/DelegateSet.h>
#endif
TRANSACTION(ttDELEGATE_SET, 64, DelegateSet,
Delegation::notDelegable,
@@ -827,7 +827,7 @@ TRANSACTION(ttDELEGATE_SET, 64, DelegateSet,
/** This transaction creates a single asset vault. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/VaultCreate.h>
# include <xrpl/tx/transactors/Vault/VaultCreate.h>
#endif
TRANSACTION(ttVAULT_CREATE, 65, VaultCreate,
Delegation::delegable,
@@ -845,7 +845,7 @@ TRANSACTION(ttVAULT_CREATE, 65, VaultCreate,
/** This transaction updates a single asset vault. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/VaultSet.h>
# include <xrpl/tx/transactors/Vault/VaultSet.h>
#endif
TRANSACTION(ttVAULT_SET, 66, VaultSet,
Delegation::delegable,
@@ -860,7 +860,7 @@ TRANSACTION(ttVAULT_SET, 66, VaultSet,
/** This transaction deletes a single asset vault. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/VaultDelete.h>
# include <xrpl/tx/transactors/Vault/VaultDelete.h>
#endif
TRANSACTION(ttVAULT_DELETE, 67, VaultDelete,
Delegation::delegable,
@@ -872,7 +872,7 @@ TRANSACTION(ttVAULT_DELETE, 67, VaultDelete,
/** This transaction trades assets for shares with a vault. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/VaultDeposit.h>
# include <xrpl/tx/transactors/Vault/VaultDeposit.h>
#endif
TRANSACTION(ttVAULT_DEPOSIT, 68, VaultDeposit,
Delegation::delegable,
@@ -885,7 +885,7 @@ TRANSACTION(ttVAULT_DEPOSIT, 68, VaultDeposit,
/** This transaction trades shares for assets with a vault. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/VaultWithdraw.h>
# include <xrpl/tx/transactors/Vault/VaultWithdraw.h>
#endif
TRANSACTION(ttVAULT_WITHDRAW, 69, VaultWithdraw,
Delegation::delegable,
@@ -900,7 +900,7 @@ TRANSACTION(ttVAULT_WITHDRAW, 69, VaultWithdraw,
/** This transaction claws back tokens from a vault. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/VaultClawback.h>
# include <xrpl/tx/transactors/Vault/VaultClawback.h>
#endif
TRANSACTION(ttVAULT_CLAWBACK, 70, VaultClawback,
Delegation::delegable,
@@ -914,7 +914,7 @@ TRANSACTION(ttVAULT_CLAWBACK, 70, VaultClawback,
/** This transaction type batches together transactions. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/Batch.h>
# include <xrpl/tx/transactors/Batch.h>
#endif
TRANSACTION(ttBATCH, 71, Batch,
Delegation::notDelegable,
@@ -929,7 +929,7 @@ TRANSACTION(ttBATCH, 71, Batch,
/** This transaction creates and updates a Loan Broker */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanBrokerSet.h>
# include <xrpl/tx/transactors/Lending/LoanBrokerSet.h>
#endif
TRANSACTION(ttLOAN_BROKER_SET, 74, LoanBrokerSet,
Delegation::delegable,
@@ -946,7 +946,7 @@ TRANSACTION(ttLOAN_BROKER_SET, 74, LoanBrokerSet,
/** This transaction deletes a Loan Broker */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanBrokerDelete.h>
# include <xrpl/tx/transactors/Lending/LoanBrokerDelete.h>
#endif
TRANSACTION(ttLOAN_BROKER_DELETE, 75, LoanBrokerDelete,
Delegation::delegable,
@@ -957,7 +957,7 @@ TRANSACTION(ttLOAN_BROKER_DELETE, 75, LoanBrokerDelete,
/** This transaction deposits First Loss Capital into a Loan Broker */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanBrokerCoverDeposit.h>
# include <xrpl/tx/transactors/Lending/LoanBrokerCoverDeposit.h>
#endif
TRANSACTION(ttLOAN_BROKER_COVER_DEPOSIT, 76, LoanBrokerCoverDeposit,
Delegation::delegable,
@@ -969,7 +969,7 @@ TRANSACTION(ttLOAN_BROKER_COVER_DEPOSIT, 76, LoanBrokerCoverDeposit,
/** This transaction withdraws First Loss Capital from a Loan Broker */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanBrokerCoverWithdraw.h>
# include <xrpl/tx/transactors/Lending/LoanBrokerCoverWithdraw.h>
#endif
TRANSACTION(ttLOAN_BROKER_COVER_WITHDRAW, 77, LoanBrokerCoverWithdraw,
Delegation::delegable,
@@ -984,7 +984,7 @@ TRANSACTION(ttLOAN_BROKER_COVER_WITHDRAW, 77, LoanBrokerCoverWithdraw,
/** This transaction claws back First Loss Capital from a Loan Broker to
the issuer of the capital */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanBrokerCoverClawback.h>
# include <xrpl/tx/transactors/Lending/LoanBrokerCoverClawback.h>
#endif
TRANSACTION(ttLOAN_BROKER_COVER_CLAWBACK, 78, LoanBrokerCoverClawback,
Delegation::delegable,
@@ -996,7 +996,7 @@ TRANSACTION(ttLOAN_BROKER_COVER_CLAWBACK, 78, LoanBrokerCoverClawback,
/** This transaction creates a Loan */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanSet.h>
# include <xrpl/tx/transactors/Lending/LoanSet.h>
#endif
TRANSACTION(ttLOAN_SET, 80, LoanSet,
Delegation::delegable,
@@ -1023,7 +1023,7 @@ TRANSACTION(ttLOAN_SET, 80, LoanSet,
/** This transaction deletes an existing Loan */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanDelete.h>
# include <xrpl/tx/transactors/Lending/LoanDelete.h>
#endif
TRANSACTION(ttLOAN_DELETE, 81, LoanDelete,
Delegation::delegable,
@@ -1034,7 +1034,7 @@ TRANSACTION(ttLOAN_DELETE, 81, LoanDelete,
/** This transaction is used to change the delinquency status of an existing Loan */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanManage.h>
# include <xrpl/tx/transactors/Lending/LoanManage.h>
#endif
TRANSACTION(ttLOAN_MANAGE, 82, LoanManage,
Delegation::delegable,
@@ -1048,7 +1048,7 @@ TRANSACTION(ttLOAN_MANAGE, 82, LoanManage,
/** The Borrower uses this transaction to make a Payment on the Loan. */
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/LoanPay.h>
# include <xrpl/tx/transactors/Lending/LoanPay.h>
#endif
TRANSACTION(ttLOAN_PAY, 84, LoanPay,
Delegation::delegable,
@@ -1063,7 +1063,7 @@ TRANSACTION(ttLOAN_PAY, 84, LoanPay,
For details, see: https://xrpl.org/amendments.html
*/
#if TRANSACTION_INCLUDE
# include <xrpld/app/tx/detail/Change.h>
# include <xrpl/tx/transactors/Change.h>
#endif
TRANSACTION(ttAMENDMENT, 100, EnableAmendment,
Delegation::notDelegable,

View File

@@ -218,7 +218,7 @@ void
BaseHTTPPeer<Handler, Impl>::close()
{
if (!strand_.running_in_this_thread())
return post(strand_, std::bind((void(BaseHTTPPeer::*)(void)) & BaseHTTPPeer::close, impl().shared_from_this()));
return post(strand_, std::bind((void (BaseHTTPPeer::*)(void))&BaseHTTPPeer::close, impl().shared_from_this()));
boost::beast::get_lowest_layer(impl().stream_).close();
}
@@ -436,7 +436,7 @@ BaseHTTPPeer<Handler, Impl>::close(bool graceful)
return post(
strand_,
std::bind(
(void(BaseHTTPPeer::*)(bool)) & BaseHTTPPeer<Handler, Impl>::close,
(void (BaseHTTPPeer::*)(bool))&BaseHTTPPeer<Handler, Impl>::close,
impl().shared_from_this(),
graceful));

View File

@@ -178,8 +178,9 @@ BaseWSPeer<Handler, Impl>::run()
impl().ws_.control_callback(control_callback_);
start_timer();
close_on_timer_ = true;
impl().ws_.set_option(boost::beast::websocket::stream_base::decorator(
[](auto& res) { res.set(boost::beast::http::field::server, BuildInfo::getFullVersionString()); }));
impl().ws_.set_option(boost::beast::websocket::stream_base::decorator([](auto& res) {
res.set(boost::beast::http::field::server, BuildInfo::getFullVersionString());
}));
impl().ws_.async_accept(
request_,
bind_executor(

View File

@@ -1,9 +1,7 @@
#pragma once
#include <xrpld/app/main/Application.h>
#include <xrpld/core/Config.h>
#include <xrpl/beast/utility/Journal.h>
#include <xrpl/core/ServiceRegistry.h>
#include <xrpl/ledger/ApplyViewImpl.h>
#include <xrpl/protocol/STTx.h>
#include <xrpl/protocol/XRPAmount.h>
@@ -17,7 +15,7 @@ class ApplyContext
{
public:
explicit ApplyContext(
Application& app,
ServiceRegistry& registry,
OpenView& base,
std::optional<uint256 const> const& parentBatchId,
STTx const& tx,
@@ -27,19 +25,19 @@ public:
beast::Journal journal = beast::Journal{beast::Journal::getNullSink()});
explicit ApplyContext(
Application& app,
ServiceRegistry& registry,
OpenView& base,
STTx const& tx,
TER preclaimResult,
XRPAmount baseFee,
ApplyFlags flags,
beast::Journal journal = beast::Journal{beast::Journal::getNullSink()})
: ApplyContext(app, base, std::nullopt, tx, preclaimResult, baseFee, flags, journal)
: ApplyContext(registry, base, std::nullopt, tx, preclaimResult, baseFee, flags, journal)
{
XRPL_ASSERT((flags & tapBATCH) == 0, "Batch apply flag should not be set");
}
Application& app;
ServiceRegistry& registry;
STTx const& tx;
TER const preclaimResult;
XRPAmount const baseFee;
@@ -90,11 +88,12 @@ public:
/** Visit unapplied changes. */
void
visit(std::function<void(
uint256 const& key,
bool isDelete,
std::shared_ptr<SLE const> const& before,
std::shared_ptr<SLE const> const& after)> const& func);
visit(
std::function<void(
uint256 const& key,
bool isDelete,
std::shared_ptr<SLE const> const& before,
std::shared_ptr<SLE const> const& after)> const& func);
void
destroyXRP(XRPAmount const& fee)

View File

@@ -1,11 +1,10 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h> // NotTEC
#include <xrpl/basics/Expected.h> //
#include <xrpl/beast/utility/Journal.h> // beast::Journal
#include <xrpl/protocol/TER.h> // temMALFORMED
#include <xrpl/protocol/UintTypes.h> // AccountID
#include <xrpl/tx/Transactor.h> // NotTEC
#include <optional>
#include <string_view>

View File

@@ -1,12 +1,11 @@
#pragma once
#include <xrpld/app/tx/applySteps.h>
#include <xrpld/app/tx/detail/ApplyContext.h>
#include <xrpl/beast/utility/Journal.h>
#include <xrpl/beast/utility/WrappedSink.h>
#include <xrpl/protocol/Permissions.h>
#include <xrpl/protocol/XRPAmount.h>
#include <xrpl/tx/ApplyContext.h>
#include <xrpl/tx/applySteps.h>
namespace xrpl {
@@ -14,7 +13,7 @@ namespace xrpl {
struct PreflightContext
{
public:
Application& app;
ServiceRegistry& registry;
STTx const& tx;
Rules const rules;
ApplyFlags flags;
@@ -22,24 +21,24 @@ public:
beast::Journal const j;
PreflightContext(
Application& app_,
ServiceRegistry& registry_,
STTx const& tx_,
uint256 parentBatchId_,
Rules const& rules_,
ApplyFlags flags_,
beast::Journal j_ = beast::Journal{beast::Journal::getNullSink()})
: app(app_), tx(tx_), rules(rules_), flags(flags_), parentBatchId(parentBatchId_), j(j_)
: registry(registry_), tx(tx_), rules(rules_), flags(flags_), parentBatchId(parentBatchId_), j(j_)
{
XRPL_ASSERT((flags_ & tapBATCH) == tapBATCH, "Batch apply flag should be set");
}
PreflightContext(
Application& app_,
ServiceRegistry& registry_,
STTx const& tx_,
Rules const& rules_,
ApplyFlags flags_,
beast::Journal j_ = beast::Journal{beast::Journal::getNullSink()})
: app(app_), tx(tx_), rules(rules_), flags(flags_), j(j_)
: registry(registry_), tx(tx_), rules(rules_), flags(flags_), j(j_)
{
XRPL_ASSERT((flags_ & tapBATCH) == 0, "Batch apply flag should not be set");
}
@@ -52,7 +51,7 @@ public:
struct PreclaimContext
{
public:
Application& app;
ServiceRegistry& registry;
ReadView const& view;
TER preflightResult;
ApplyFlags flags;
@@ -61,14 +60,14 @@ public:
beast::Journal const j;
PreclaimContext(
Application& app_,
ServiceRegistry& registry_,
ReadView const& view_,
TER preflightResult_,
STTx const& tx_,
ApplyFlags flags_,
std::optional<uint256> parentBatchId_,
beast::Journal j_ = beast::Journal{beast::Journal::getNullSink()})
: app(app_)
: registry(registry_)
, view(view_)
, preflightResult(preflightResult_)
, flags(flags_)
@@ -82,13 +81,13 @@ public:
}
PreclaimContext(
Application& app_,
ServiceRegistry& registry_,
ReadView const& view_,
TER preflightResult_,
STTx const& tx_,
ApplyFlags flags_,
beast::Journal j_ = beast::Journal{beast::Journal::getNullSink()})
: PreclaimContext(app_, view_, preflightResult_, tx_, flags_, std::nullopt, j_)
: PreclaimContext(registry_, view_, preflightResult_, tx_, flags_, std::nullopt, j_)
{
XRPL_ASSERT((flags_ & tapBATCH) == 0, "Batch apply flag should not be set");
}
@@ -225,14 +224,14 @@ protected:
/** Compute the minimum fee required to process a transaction
with a given baseFee based on the current server load.
@param app The application hosting the server
@param registry The service registry.
@param baseFee The base fee of a candidate transaction
@see xrpl::calculateBaseFee
@param fees Fee settings from the current ledger
@param flags Transaction processing fees
*/
static XRPAmount
minimumFee(Application& app, XRPAmount baseFee, Fees const& fees, ApplyFlags flags);
minimumFee(ServiceRegistry& registry, XRPAmount baseFee, Fees const& fees, ApplyFlags flags);
// Returns the fee in fee units, not scaled for load.
static XRPAmount

View File

@@ -1,18 +1,16 @@
#pragma once
#include <xrpld/app/tx/applySteps.h>
#include <xrpld/core/Config.h>
#include <xrpl/beast/utility/Journal.h>
#include <xrpl/ledger/View.h>
#include <xrpl/protocol/STTx.h>
#include <xrpl/tx/applySteps.h>
#include <utility>
namespace xrpl {
class Application;
class HashRouter;
class ServiceRegistry;
/** Describes the pre-processing validity of a transaction.
@@ -41,7 +39,7 @@ enum class Validity {
@see Validity
*/
std::pair<Validity, std::string>
checkValidity(HashRouter& router, STTx const& tx, Rules const& rules, Config const& config);
checkValidity(HashRouter& router, STTx const& tx, Rules const& rules);
/** Sets the validity of a given transaction in the cache.
@@ -97,7 +95,7 @@ forceValidity(HashRouter& router, uint256 const& txid, Validity validity);
whether or not the transaction was applied.
*/
ApplyResult
apply(Application& app, OpenView& view, STTx const& tx, ApplyFlags flags, beast::Journal journal);
apply(ServiceRegistry& registry, OpenView& view, STTx const& tx, ApplyFlags flags, beast::Journal journal);
/** Enum class for return value from `applyTransaction`
@@ -121,7 +119,7 @@ enum class ApplyTransactionResult {
*/
ApplyTransactionResult
applyTransaction(
Application& app,
ServiceRegistry& registry,
OpenView& view,
STTx const& tx,
bool retryAssured,

View File

@@ -5,7 +5,7 @@
namespace xrpl {
class Application;
class ServiceRegistry;
class STTx;
class TxQ;
@@ -240,11 +240,11 @@ public:
*/
/** @{ */
PreflightResult
preflight(Application& app, Rules const& rules, STTx const& tx, ApplyFlags flags, beast::Journal j);
preflight(ServiceRegistry& registry, Rules const& rules, STTx const& tx, ApplyFlags flags, beast::Journal j);
PreflightResult
preflight(
Application& app,
ServiceRegistry& registry,
Rules const& rules,
uint256 const& parentBatchId,
STTx const& tx,
@@ -281,7 +281,7 @@ preflight(
this transaction.
*/
PreclaimResult
preclaim(PreflightResult const& preflightResult, Application& app, OpenView const& view);
preclaim(PreflightResult const& preflightResult, ServiceRegistry& registry, OpenView const& view);
/** Compute only the expected base fee for a transaction.
@@ -323,7 +323,7 @@ calculateDefaultBaseFee(ReadView const& view, STTx const& tx);
@param preclaimResult The result of a previous
call to `preclaim` for the transaction.
@param app The current running `Application`.
@param registry The service registry.
@param view The open ledger that the transaction
will attempt to be applied to.
@@ -333,6 +333,6 @@ calculateDefaultBaseFee(ReadView const& view, STTx const& tx);
whether or not the transaction was applied.
*/
ApplyResult
doApply(PreclaimResult const& preclaimResult, Application& app, OpenView& view);
doApply(PreclaimResult const& preclaimResult, ServiceRegistry& registry, OpenView& view);
} // namespace xrpl

View File

@@ -1,9 +1,8 @@
#pragma once
#include <xrpld/app/paths/RippleCalc.h>
#include <xrpld/app/paths/detail/Steps.h>
#include <xrpl/protocol/Quality.h>
#include <xrpl/tx/paths/RippleCalc.h>
#include <xrpl/tx/paths/detail/Steps.h>
namespace xrpl {

View File

@@ -1,12 +1,11 @@
#pragma once
#include <xrpld/app/tx/detail/BookTip.h>
#include <xrpld/app/tx/detail/Offer.h>
#include <xrpl/basics/Log.h>
#include <xrpl/basics/chrono.h>
#include <xrpl/beast/utility/Journal.h>
#include <xrpl/ledger/View.h>
#include <xrpl/tx/paths/BookTip.h>
#include <xrpl/tx/paths/Offer.h>
#include <boost/container/flat_set.hpp>

View File

@@ -1,10 +1,9 @@
#pragma once
#include <xrpld/app/paths/detail/AmountSpec.h>
#include <xrpl/ledger/PaymentSandbox.h>
#include <xrpl/protocol/IOUAmount.h>
#include <xrpl/protocol/XRPAmount.h>
#include <xrpl/tx/paths/detail/AmountSpec.h>
#include <boost/container/flat_map.hpp>

View File

@@ -1,13 +1,12 @@
#pragma once
#include <xrpld/app/paths/detail/AmountSpec.h>
#include <xrpl/basics/Log.h>
#include <xrpl/basics/base_uint.h>
#include <xrpl/protocol/Quality.h>
#include <xrpl/protocol/QualityFunction.h>
#include <xrpl/protocol/STLedgerEntry.h>
#include <xrpl/protocol/TER.h>
#include <xrpl/tx/paths/detail/AmountSpec.h>
#include <boost/container/flat_set.hpp>

View File

@@ -1,18 +1,17 @@
#pragma once
#include <xrpld/app/misc/AMMHelpers.h>
#include <xrpld/app/paths/AMMContext.h>
#include <xrpld/app/paths/Flow.h>
#include <xrpld/app/paths/detail/AmountSpec.h>
#include <xrpld/app/paths/detail/FlatSets.h>
#include <xrpld/app/paths/detail/FlowDebugInfo.h>
#include <xrpld/app/paths/detail/Steps.h>
#include <xrpl/basics/Log.h>
#include <xrpl/ledger/Credit.h>
#include <xrpl/protocol/Feature.h>
#include <xrpl/protocol/IOUAmount.h>
#include <xrpl/protocol/XRPAmount.h>
#include <xrpl/tx/paths/Flow.h>
#include <xrpl/tx/paths/detail/AmountSpec.h>
#include <xrpl/tx/paths/detail/FlatSets.h>
#include <xrpl/tx/paths/detail/FlowDebugInfo.h>
#include <xrpl/tx/paths/detail/Steps.h>
#include <xrpl/tx/transactors/AMM/AMMContext.h>
#include <xrpl/tx/transactors/AMM/AMMHelpers.h>
#include <boost/container/flat_set.hpp>

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {
class Sandbox;

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,8 +1,7 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/ledger/View.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,9 +1,8 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/basics/Log.h>
#include <xrpl/protocol/Indexes.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,7 +1,7 @@
#pragma once
#include <xrpld/app/misc/LendingHelpers.h>
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
#include <xrpl/tx/transactors/Lending/LendingHelpers.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,9 +1,8 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/basics/Expected.h>
#include <xrpl/protocol/UintTypes.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,9 +1,8 @@
#pragma once
#include <xrpld/app/tx/detail/NFTokenUtils.h>
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/protocol/nft.h>
#include <xrpl/tx/Transactor.h>
#include <xrpl/tx/transactors/NFT/NFTokenUtils.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,12 +1,11 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/basics/base_uint.h>
#include <xrpl/ledger/ApplyView.h>
#include <xrpl/protocol/AccountID.h>
#include <xrpl/protocol/TER.h>
#include <xrpl/protocol/nft.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,8 +1,7 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/protocol/TxFlags.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,8 +1,7 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/protocol/Quality.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

View File

@@ -1,6 +1,6 @@
#pragma once
#include <xrpld/app/tx/detail/Transactor.h>
#include <xrpl/tx/Transactor.h>
namespace xrpl {

Some files were not shown because too many files have changed in this diff Show More