rippled
Protocol.h
1 //------------------------------------------------------------------------------
2 /*
3  This file is part of rippled: https://github.com/ripple/rippled
4  Copyright (c) 2012, 2013 Ripple Labs Inc.
5 
6  Permission to use, copy, modify, and/or distribute this software for any
7  purpose with or without fee is hereby granted, provided that the above
8  copyright notice and this permission notice appear in all copies.
9 
10  THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11  WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12  MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13  ANY SPECIAL , DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14  WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15  ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16  OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 */
18 //==============================================================================
19 
20 #ifndef RIPPLE_PROTOCOL_PROTOCOL_H_INCLUDED
21 #define RIPPLE_PROTOCOL_PROTOCOL_H_INCLUDED
22 
23 #include <ripple/basics/ByteUtilities.h>
24 #include <ripple/basics/base_uint.h>
25 #include <cstdint>
26 
27 namespace ripple {
28 
40 std::size_t constexpr txMinSizeBytes = 32;
41 
44 
47 
50 
53 
56 
58 std::uint64_t constexpr dirNodeMaxPages = 262144;
59 
62 
65 
68 
71 
81 std::uint16_t constexpr maxTransferFee = 50000;
82 
85 
87 std::size_t constexpr maxDomainLength = 256;
88 
91 
96 using TxID = uint256;
97 
98 } // namespace ripple
99 
100 #endif
ripple::maxTransferFee
constexpr std::uint16_t maxTransferFee
The maximum token transfer fee allowed.
Definition: Protocol.h:81
ripple::maxDeletableTokenOfferEntries
constexpr std::size_t maxDeletableTokenOfferEntries
The maximum number of offers in an offer directory for NFT to be burnable.
Definition: Protocol.h:70
ripple::txMinSizeBytes
constexpr std::size_t txMinSizeBytes
Protocol specific constants.
Definition: Protocol.h:40
ripple::expiredOfferRemoveLimit
constexpr std::size_t expiredOfferRemoveLimit
The maximum number of expired offers to delete at once.
Definition: Protocol.h:49
ripple::dirNodeMaxPages
constexpr std::uint64_t dirNodeMaxPages
The maximum number of pages allowed in a directory.
Definition: Protocol.h:58
ripple::dirMaxTokensPerPage
constexpr std::size_t dirMaxTokensPerPage
The maximum number of items in an NFT page.
Definition: Protocol.h:61
ripple::unfundedOfferRemoveLimit
constexpr std::size_t unfundedOfferRemoveLimit
The maximum number of unfunded offers to delete at once.
Definition: Protocol.h:46
ripple::uint256
base_uint< 256 > uint256
Definition: base_uint.h:550
ripple::base_uint< 256 >
ripple::maxDeletableDirEntries
constexpr std::size_t maxDeletableDirEntries
The maximum number of owner directory entries for account to be deletable.
Definition: Protocol.h:64
ripple::megabytes
constexpr auto megabytes(T value) noexcept
Definition: ByteUtilities.h:34
cstdint
ripple::maxTokenOfferCancelCount
constexpr std::size_t maxTokenOfferCancelCount
The maximum number of token offers that can be canceled at once.
Definition: Protocol.h:67
std::uint64_t
ripple::txMaxSizeBytes
constexpr std::size_t txMaxSizeBytes
Largest legal byte size of a transaction.
Definition: Protocol.h:43
ripple::maxTokenURILength
constexpr std::size_t maxTokenURILength
The maximum length of a URI inside an NFT.
Definition: Protocol.h:84
ripple
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
Definition: RCLCensorshipDetector.h:29
ripple::oversizeMetaDataCap
constexpr std::size_t oversizeMetaDataCap
The maximum number of metadata entries allowed in one transaction.
Definition: Protocol.h:52
std::size_t
ripple::dirNodeMaxEntries
constexpr std::size_t dirNodeMaxEntries
The maximum number of entries per directory page.
Definition: Protocol.h:55
ripple::maxDomainLength
constexpr std::size_t maxDomainLength
The maximum length of a domain.
Definition: Protocol.h:87