rippled
TER.cpp
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 #include <ripple/protocol/TER.h>
21 #include <boost/range/adaptor/transformed.hpp>
22 #include <unordered_map>
23 #include <type_traits>
24 
25 namespace ripple {
26 
27 namespace detail {
28 
29 static
34 {
35  static
39  results
40  {
41  { tecCLAIM, { "tecCLAIM", "Fee claimed. Sequence used. No action." } },
42  { tecDIR_FULL, { "tecDIR_FULL", "Can not add entry to full directory." } },
43  { tecFAILED_PROCESSING, { "tecFAILED_PROCESSING", "Failed to correctly process transaction." } },
44  { tecINSUF_RESERVE_LINE, { "tecINSUF_RESERVE_LINE", "Insufficient reserve to add trust line." } },
45  { tecINSUF_RESERVE_OFFER, { "tecINSUF_RESERVE_OFFER", "Insufficient reserve to create offer." } },
46  { tecNO_DST, { "tecNO_DST", "Destination does not exist. Send XRP to create it." } },
47  { tecNO_DST_INSUF_XRP, { "tecNO_DST_INSUF_XRP", "Destination does not exist. Too little XRP sent to create it." } },
48  { tecNO_LINE_INSUF_RESERVE, { "tecNO_LINE_INSUF_RESERVE", "No such line. Too little reserve to create it." } },
49  { tecNO_LINE_REDUNDANT, { "tecNO_LINE_REDUNDANT", "Can't set non-existent line to default." } },
50  { tecPATH_DRY, { "tecPATH_DRY", "Path could not send partial amount." } },
51  { tecPATH_PARTIAL, { "tecPATH_PARTIAL", "Path could not send full amount." } },
52  { tecNO_ALTERNATIVE_KEY, { "tecNO_ALTERNATIVE_KEY", "The operation would remove the ability to sign transactions with the account." } },
53  { tecNO_REGULAR_KEY, { "tecNO_REGULAR_KEY", "Regular key is not set." } },
54  { tecOVERSIZE, { "tecOVERSIZE", "Object exceeded serialization limits." } },
55  { tecUNFUNDED, { "tecUNFUNDED", "One of _ADD, _OFFER, or _SEND. Deprecated." } },
56  { tecUNFUNDED_ADD, { "tecUNFUNDED_ADD", "Insufficient XRP balance for WalletAdd." } },
57  { tecUNFUNDED_OFFER, { "tecUNFUNDED_OFFER", "Insufficient balance to fund created offer." } },
58  { tecUNFUNDED_PAYMENT, { "tecUNFUNDED_PAYMENT", "Insufficient XRP balance to send." } },
59  { tecOWNERS, { "tecOWNERS", "Non-zero owner count." } },
60  { tecNO_ISSUER, { "tecNO_ISSUER", "Issuer account does not exist." } },
61  { tecNO_AUTH, { "tecNO_AUTH", "Not authorized to hold asset." } },
62  { tecNO_LINE, { "tecNO_LINE", "No such line." } },
63  { tecINSUFF_FEE, { "tecINSUFF_FEE", "Insufficient balance to pay fee." } },
64  { tecFROZEN, { "tecFROZEN", "Asset is frozen." } },
65  { tecNO_TARGET, { "tecNO_TARGET", "Target account does not exist." } },
66  { tecNO_PERMISSION, { "tecNO_PERMISSION", "No permission to perform requested operation." } },
67  { tecNO_ENTRY, { "tecNO_ENTRY", "No matching entry found." } },
68  { tecINSUFFICIENT_RESERVE, { "tecINSUFFICIENT_RESERVE", "Insufficient reserve to complete requested operation." } },
69  { tecNEED_MASTER_KEY, { "tecNEED_MASTER_KEY", "The operation requires the use of the Master Key." } },
70  { tecDST_TAG_NEEDED, { "tecDST_TAG_NEEDED", "A destination tag is required." } },
71  { tecINTERNAL, { "tecINTERNAL", "An internal error has occurred during processing." } },
72  { tecCRYPTOCONDITION_ERROR, { "tecCRYPTOCONDITION_ERROR", "Malformed, invalid, or mismatched conditional or fulfillment." } },
73  { tecINVARIANT_FAILED, { "tecINVARIANT_FAILED", "One or more invariants for the transaction were not satisfied." } },
74  { tecEXPIRED, { "tecEXPIRED", "Expiration time is passed." } },
75  { tecDUPLICATE, { "tecDUPLICATE", "Ledger object already exists." } },
76  { tecKILLED, { "tecKILLED", "FillOrKill offer killed." } },
77  { tecHAS_OBLIGATIONS, { "tecHAS_OBLIGATIONS", "The account cannot be deleted since it has obligations." } },
78  { tecTOO_SOON, { "tecTOO_SOON", "It is too early to attempt the requested operation. Please wait." } },
79 
80  { tefALREADY, { "tefALREADY", "The exact transaction was already in this ledger." } },
81  { tefBAD_ADD_AUTH, { "tefBAD_ADD_AUTH", "Not authorized to add account." } },
82  { tefBAD_AUTH, { "tefBAD_AUTH", "Transaction's public key is not authorized." } },
83  { tefBAD_LEDGER, { "tefBAD_LEDGER", "Ledger in unexpected state." } },
84  { tefBAD_QUORUM, { "tefBAD_QUORUM", "Signatures provided do not meet the quorum." } },
85  { tefBAD_SIGNATURE, { "tefBAD_SIGNATURE", "A signature is provided for a non-signer." } },
86  { tefCREATED, { "tefCREATED", "Can't add an already created account." } },
87  { tefEXCEPTION, { "tefEXCEPTION", "Unexpected program state." } },
88  { tefFAILURE, { "tefFAILURE", "Failed to apply." } },
89  { tefINTERNAL, { "tefINTERNAL", "Internal error." } },
90  { tefMASTER_DISABLED, { "tefMASTER_DISABLED", "Master key is disabled." } },
91  { tefMAX_LEDGER, { "tefMAX_LEDGER", "Ledger sequence too high." } },
92  { tefNO_AUTH_REQUIRED, { "tefNO_AUTH_REQUIRED", "Auth is not required." } },
93  { tefNOT_MULTI_SIGNING, { "tefNOT_MULTI_SIGNING", "Account has no appropriate list of multi-signers." } },
94  { tefPAST_SEQ, { "tefPAST_SEQ", "This sequence number has already passed." } },
95  { tefWRONG_PRIOR, { "tefWRONG_PRIOR", "This previous transaction does not match." } },
96  { tefBAD_AUTH_MASTER, { "tefBAD_AUTH_MASTER", "Auth for unclaimed account needs correct master key." } },
97  { tefINVARIANT_FAILED, { "tefINVARIANT_FAILED", "Fee claim violated invariants for the transaction." } },
98  { tefTOO_BIG, { "tefTOO_BIG", "Transaction affects too many items." } },
99 
100  { telLOCAL_ERROR, { "telLOCAL_ERROR", "Local failure." } },
101  { telBAD_DOMAIN, { "telBAD_DOMAIN", "Domain too long." } },
102  { telBAD_PATH_COUNT, { "telBAD_PATH_COUNT", "Malformed: Too many paths." } },
103  { telBAD_PUBLIC_KEY, { "telBAD_PUBLIC_KEY", "Public key too long." } },
104  { telFAILED_PROCESSING, { "telFAILED_PROCESSING", "Failed to correctly process transaction." } },
105  { telINSUF_FEE_P, { "telINSUF_FEE_P", "Fee insufficient." } },
106  { telNO_DST_PARTIAL, { "telNO_DST_PARTIAL", "Partial payment to create account not allowed." } },
107  { telCAN_NOT_QUEUE, { "telCAN_NOT_QUEUE", "Can not queue at this time." } },
108  { telCAN_NOT_QUEUE_BALANCE, { "telCAN_NOT_QUEUE_BALANCE", "Can not queue at this time: insufficient balance to pay all queued fees." } },
109  { telCAN_NOT_QUEUE_BLOCKS, { "telCAN_NOT_QUEUE_BLOCKS", "Can not queue at this time: would block later queued transaction(s)." } },
110  { telCAN_NOT_QUEUE_BLOCKED, { "telCAN_NOT_QUEUE_BLOCKED", "Can not queue at this time: blocking transaction in queue." } },
111  { telCAN_NOT_QUEUE_FEE, { "telCAN_NOT_QUEUE_FEE", "Can not queue at this time: fee insufficient to replace queued transaction." } },
112  { telCAN_NOT_QUEUE_FULL, { "telCAN_NOT_QUEUE_FULL", "Can not queue at this time: queue is full." } },
113 
114  { temMALFORMED, { "temMALFORMED", "Malformed transaction." } },
115  { temBAD_AMOUNT, { "temBAD_AMOUNT", "Can only send positive amounts." } },
116  { temBAD_CURRENCY, { "temBAD_CURRENCY", "Malformed: Bad currency." } },
117  { temBAD_EXPIRATION, { "temBAD_EXPIRATION", "Malformed: Bad expiration." } },
118  { temBAD_FEE, { "temBAD_FEE", "Invalid fee, negative or not XRP." } },
119  { temBAD_ISSUER, { "temBAD_ISSUER", "Malformed: Bad issuer." } },
120  { temBAD_LIMIT, { "temBAD_LIMIT", "Limits must be non-negative." } },
121  { temBAD_OFFER, { "temBAD_OFFER", "Malformed: Bad offer." } },
122  { temBAD_PATH, { "temBAD_PATH", "Malformed: Bad path." } },
123  { temBAD_PATH_LOOP, { "temBAD_PATH_LOOP", "Malformed: Loop in path." } },
124  { temBAD_QUORUM, { "temBAD_QUORUM", "Malformed: Quorum is unreachable." } },
125  { temBAD_REGKEY, { "temBAD_REGKEY", "Malformed: Regular key cannot be same as master key." } },
126  { temBAD_SEND_XRP_LIMIT, { "temBAD_SEND_XRP_LIMIT", "Malformed: Limit quality is not allowed for XRP to XRP." } },
127  { temBAD_SEND_XRP_MAX, { "temBAD_SEND_XRP_MAX", "Malformed: Send max is not allowed for XRP to XRP." } },
128  { temBAD_SEND_XRP_NO_DIRECT, { "temBAD_SEND_XRP_NO_DIRECT","Malformed: No Ripple direct is not allowed for XRP to XRP." } },
129  { temBAD_SEND_XRP_PARTIAL, { "temBAD_SEND_XRP_PARTIAL", "Malformed: Partial payment is not allowed for XRP to XRP." } },
130  { temBAD_SEND_XRP_PATHS, { "temBAD_SEND_XRP_PATHS", "Malformed: Paths are not allowed for XRP to XRP." } },
131  { temBAD_SEQUENCE, { "temBAD_SEQUENCE", "Malformed: Sequence is not in the past." } },
132  { temBAD_SIGNATURE, { "temBAD_SIGNATURE", "Malformed: Bad signature." } },
133  { temBAD_SIGNER, { "temBAD_SIGNER", "Malformed: No signer may duplicate account or other signers." } },
134  { temBAD_SRC_ACCOUNT, { "temBAD_SRC_ACCOUNT", "Malformed: Bad source account." } },
135  { temBAD_TRANSFER_RATE, { "temBAD_TRANSFER_RATE", "Malformed: Transfer rate must be >= 1.0 and <= 2.0" } },
136  { temBAD_WEIGHT, { "temBAD_WEIGHT", "Malformed: Weight must be a positive value." } },
137  { temDST_IS_SRC, { "temDST_IS_SRC", "Destination may not be source." } },
138  { temDST_NEEDED, { "temDST_NEEDED", "Destination not specified." } },
139  { temINVALID, { "temINVALID", "The transaction is ill-formed." } },
140  { temINVALID_FLAG, { "temINVALID_FLAG", "The transaction has an invalid flag." } },
141  { temREDUNDANT, { "temREDUNDANT", "Sends same currency to self." } },
142  { temRIPPLE_EMPTY, { "temRIPPLE_EMPTY", "PathSet with no paths." } },
143  { temUNCERTAIN, { "temUNCERTAIN", "In process of determining result. Never returned." } },
144  { temUNKNOWN, { "temUNKNOWN", "The transaction requires logic that is not implemented yet." } },
145  { temDISABLED, { "temDISABLED", "The transaction requires logic that is currently disabled." } },
146  { temBAD_TICK_SIZE, { "temBAD_TICK_SIZE", "Malformed: Tick size out of range." } },
147  { temINVALID_ACCOUNT_ID, { "temINVALID_ACCOUNT_ID", "Malformed: A field contains an invalid account ID." } },
148  { temCANNOT_PREAUTH_SELF, { "temCANNOT_PREAUTH_SELF", "Malformed: An account may not preauthorize itself." } },
149 
150  { terRETRY, { "terRETRY", "Retry transaction." } },
151  { terFUNDS_SPENT, { "terFUNDS_SPENT", "Can't set password, password set funds already spent." } },
152  { terINSUF_FEE_B, { "terINSUF_FEE_B", "Account balance can't pay fee." } },
153  { terLAST, { "terLAST", "Process last." } },
154  { terNO_RIPPLE, { "terNO_RIPPLE", "Path does not permit rippling." } },
155  { terNO_ACCOUNT, { "terNO_ACCOUNT", "The source account does not exist." } },
156  { terNO_AUTH, { "terNO_AUTH", "Not authorized to hold IOUs." } },
157  { terNO_LINE, { "terNO_LINE", "No such line." } },
158  { terPRE_SEQ, { "terPRE_SEQ", "Missing/inapplicable prior transaction." } },
159  { terOWNERS, { "terOWNERS", "Non-zero owner count." } },
160  { terQUEUED, { "terQUEUED", "Held until escalated fee drops." } },
161 
162  { tesSUCCESS, { "tesSUCCESS", "The transaction was applied. Only final in a validated ledger." } },
163  };
164  return results;
165 }
166 
167 }
168 
169 bool transResultInfo (TER code, std::string& token, std::string& text)
170 {
171  auto& results = detail::transResults();
172 
173  auto const r = results.find (TERtoInt (code));
174 
175  if (r == results.end())
176  return false;
177 
178  token = r->second.first;
179  text = r->second.second;
180  return true;
181 }
182 
184 {
185  std::string token;
186  std::string text;
187 
188  return transResultInfo (code, token, text) ? token : "-";
189 }
190 
192 {
193  std::string token;
194  std::string text;
195 
196  return transResultInfo (code, token, text) ? text : "-";
197 }
198 
199 boost::optional<TER>
200 transCode(std::string const& token)
201 {
202  static
203  auto const results = []
204  {
205  auto& byTer = detail::transResults();
206  auto range = boost::make_iterator_range(byTer.begin(),
207  byTer.end());
208  auto tRange = boost::adaptors::transform(
209  range,
210  [](auto const& r)
211  {
212  return std::make_pair(r.second.first, r.first);
213  }
214  );
216  std::string,
217  TERUnderlyingType> const
218  byToken(tRange.begin(), tRange.end());
219  return byToken;
220  }();
221 
222  auto const r = results.find(token);
223 
224  if (r == results.end())
225  return boost::none;
226 
227  return TER::fromInt (r->second);
228 }
229 
230 } // ripple
ripple::tecUNFUNDED_OFFER
@ tecUNFUNDED_OFFER
Definition: TER.h:249
ripple::tecFROZEN
@ tecFROZEN
Definition: TER.h:268
ripple::tecNO_TARGET
@ tecNO_TARGET
Definition: TER.h:269
ripple::temBAD_SEND_XRP_MAX
@ temBAD_SEND_XRP_MAX
Definition: TER.h:98
ripple::tefINTERNAL
@ tefINTERNAL
Definition: TER.h:153
ripple::tecINVARIANT_FAILED
@ tecINVARIANT_FAILED
Definition: TER.h:278
ripple::tecINSUF_RESERVE_LINE
@ tecINSUF_RESERVE_LINE
Definition: TER.h:253
std::string
STL class.
ripple::temBAD_OFFER
@ temBAD_OFFER
Definition: TER.h:93
ripple::tefBAD_ADD_AUTH
@ tefBAD_ADD_AUTH
Definition: TER.h:148
ripple::terINSUF_FEE_B
@ terINSUF_FEE_B
Definition: TER.h:194
ripple::temBAD_CURRENCY
@ temBAD_CURRENCY
Definition: TER.h:88
ripple::terNO_LINE
@ terNO_LINE
Definition: TER.h:197
ripple::tecOWNERS
@ tecOWNERS
Definition: TER.h:263
ripple::telLOCAL_ERROR
@ telLOCAL_ERROR
Definition: TER.h:53
std::pair
ripple::tefINVARIANT_FAILED
@ tefINVARIANT_FAILED
Definition: TER.h:163
ripple::tecNO_REGULAR_KEY
@ tecNO_REGULAR_KEY
Definition: TER.h:262
ripple::telCAN_NOT_QUEUE_FEE
@ telCAN_NOT_QUEUE_FEE
Definition: TER.h:64
ripple::temBAD_REGKEY
@ temBAD_REGKEY
Definition: TER.h:96
ripple::telBAD_DOMAIN
@ telBAD_DOMAIN
Definition: TER.h:54
ripple::tecDST_TAG_NEEDED
@ tecDST_TAG_NEEDED
Definition: TER.h:274
ripple::terFUNDS_SPENT
@ terFUNDS_SPENT
Definition: TER.h:193
ripple::temCANNOT_PREAUTH_SELF
@ temCANNOT_PREAUTH_SELF
Definition: TER.h:118
ripple::transToken
std::string transToken(TER code)
Definition: TER.cpp:183
ripple::telCAN_NOT_QUEUE_FULL
@ telCAN_NOT_QUEUE_FULL
Definition: TER.h:65
ripple::telCAN_NOT_QUEUE
@ telCAN_NOT_QUEUE
Definition: TER.h:60
ripple::TERUnderlyingType
int TERUnderlyingType
Definition: TER.h:37
ripple::TERtoInt
constexpr TERUnderlyingType TERtoInt(TELcodes v)
Definition: TER.h:289
ripple::terNO_RIPPLE
@ terNO_RIPPLE
Definition: TER.h:202
ripple::temBAD_ISSUER
@ temBAD_ISSUER
Definition: TER.h:91
ripple::tefCREATED
@ tefCREATED
Definition: TER.h:151
ripple::temBAD_TRANSFER_RATE
@ temBAD_TRANSFER_RATE
Definition: TER.h:105
ripple::temBAD_PATH
@ temBAD_PATH
Definition: TER.h:94
ripple::temDST_IS_SRC
@ temDST_IS_SRC
Definition: TER.h:106
ripple::tefBAD_AUTH
@ tefBAD_AUTH
Definition: TER.h:149
ripple::detail::transResults
static std::unordered_map< TERUnderlyingType, std::pair< char const *const, char const *const > > const & transResults()
Definition: TER.cpp:33
ripple::tecKILLED
@ tecKILLED
Definition: TER.h:281
ripple::temUNCERTAIN
@ temUNCERTAIN
Definition: TER.h:121
ripple::terQUEUED
@ terQUEUED
Definition: TER.h:203
ripple::tefBAD_QUORUM
@ tefBAD_QUORUM
Definition: TER.h:160
ripple::tecOVERSIZE
@ tecOVERSIZE
Definition: TER.h:276
ripple::tecNO_DST_INSUF_XRP
@ tecNO_DST_INSUF_XRP
Definition: TER.h:256
ripple::temINVALID_FLAG
@ temINVALID_FLAG
Definition: TER.h:109
ripple::tefBAD_LEDGER
@ tefBAD_LEDGER
Definition: TER.h:150
ripple::temBAD_QUORUM
@ temBAD_QUORUM
Definition: TER.h:114
ripple::telFAILED_PROCESSING
@ telFAILED_PROCESSING
Definition: TER.h:57
ripple::tecNO_ALTERNATIVE_KEY
@ tecNO_ALTERNATIVE_KEY
Definition: TER.h:261
ripple::temBAD_SEND_XRP_PARTIAL
@ temBAD_SEND_XRP_PARTIAL
Definition: TER.h:100
ripple::tefMAX_LEDGER
@ tefMAX_LEDGER
Definition: TER.h:158
ripple::tefMASTER_DISABLED
@ tefMASTER_DISABLED
Definition: TER.h:157
ripple::temBAD_LIMIT
@ temBAD_LIMIT
Definition: TER.h:92
ripple::terRETRY
@ terRETRY
Definition: TER.h:192
ripple::temBAD_SIGNER
@ temBAD_SIGNER
Definition: TER.h:113
ripple::tecDUPLICATE
@ tecDUPLICATE
Definition: TER.h:280
ripple::temBAD_SEND_XRP_PATHS
@ temBAD_SEND_XRP_PATHS
Definition: TER.h:101
ripple::TERSubset< CanCvtToTER >
ripple::terLAST
@ terLAST
Definition: TER.h:201
ripple::tecFAILED_PROCESSING
@ tecFAILED_PROCESSING
Definition: TER.h:251
ripple::temDST_NEEDED
@ temDST_NEEDED
Definition: TER.h:107
ripple::temBAD_SEQUENCE
@ temBAD_SEQUENCE
Definition: TER.h:102
ripple::terOWNERS
@ terOWNERS
Definition: TER.h:198
ripple::tecUNFUNDED
@ tecUNFUNDED
Definition: TER.h:260
ripple::temBAD_SRC_ACCOUNT
@ temBAD_SRC_ACCOUNT
Definition: TER.h:104
ripple::telINSUF_FEE_P
@ telINSUF_FEE_P
Definition: TER.h:58
ripple::terNO_AUTH
@ terNO_AUTH
Definition: TER.h:196
ripple::tecNO_LINE_REDUNDANT
@ tecNO_LINE_REDUNDANT
Definition: TER.h:258
ripple::tecUNFUNDED_PAYMENT
@ tecUNFUNDED_PAYMENT
Definition: TER.h:250
ripple::tecINTERNAL
@ tecINTERNAL
Definition: TER.h:275
ripple::temBAD_AMOUNT
@ temBAD_AMOUNT
Definition: TER.h:87
ripple::tecINSUFF_FEE
@ tecINSUFF_FEE
Definition: TER.h:267
ripple::temBAD_SEND_XRP_NO_DIRECT
@ temBAD_SEND_XRP_NO_DIRECT
Definition: TER.h:99
ripple::telBAD_PATH_COUNT
@ telBAD_PATH_COUNT
Definition: TER.h:55
ripple::temBAD_SIGNATURE
@ temBAD_SIGNATURE
Definition: TER.h:103
ripple::temUNKNOWN
@ temUNKNOWN
Definition: TER.h:122
ripple::tecPATH_PARTIAL
@ tecPATH_PARTIAL
Definition: TER.h:247
ripple::temREDUNDANT
@ temREDUNDANT
Definition: TER.h:110
ripple::tefFAILURE
@ tefFAILURE
Definition: TER.h:146
ripple::range
ClosedInterval< T > range(T low, T high)
Create a closed range interval.
Definition: RangeSet.h:54
ripple::temBAD_FEE
@ temBAD_FEE
Definition: TER.h:90
ripple::telCAN_NOT_QUEUE_BLOCKS
@ telCAN_NOT_QUEUE_BLOCKS
Definition: TER.h:62
ripple::tecNEED_MASTER_KEY
@ tecNEED_MASTER_KEY
Definition: TER.h:273
ripple::transHuman
std::string transHuman(TER code)
Definition: TER.cpp:191
ripple::tecUNFUNDED_ADD
@ tecUNFUNDED_ADD
Definition: TER.h:248
ripple::tecDIR_FULL
@ tecDIR_FULL
Definition: TER.h:252
ripple::terNO_ACCOUNT
@ terNO_ACCOUNT
Definition: TER.h:195
ripple::tecTOO_SOON
@ tecTOO_SOON
Definition: TER.h:283
ripple::tefNOT_MULTI_SIGNING
@ tefNOT_MULTI_SIGNING
Definition: TER.h:161
ripple
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
Definition: RCLCensorshipDetector.h:29
ripple::transResultInfo
bool transResultInfo(TER code, std::string &token, std::string &text)
Definition: TER.cpp:169
ripple::tefNO_AUTH_REQUIRED
@ tefNO_AUTH_REQUIRED
Definition: TER.h:154
ripple::temINVALID_ACCOUNT_ID
@ temINVALID_ACCOUNT_ID
Definition: TER.h:117
ripple::tecNO_LINE_INSUF_RESERVE
@ tecNO_LINE_INSUF_RESERVE
Definition: TER.h:257
ripple::tefPAST_SEQ
@ tefPAST_SEQ
Definition: TER.h:155
ripple::tecNO_LINE
@ tecNO_LINE
Definition: TER.h:266
ripple::tecEXPIRED
@ tecEXPIRED
Definition: TER.h:279
ripple::temDISABLED
@ temDISABLED
Definition: TER.h:112
ripple::transCode
boost::optional< TER > transCode(std::string const &token)
Definition: TER.cpp:200
ripple::tefALREADY
@ tefALREADY
Definition: TER.h:147
ripple::TERSubset< CanCvtToTER >::fromInt
static constexpr TERSubset fromInt(int from)
Definition: TER.h:323
ripple::tecNO_ISSUER
@ tecNO_ISSUER
Definition: TER.h:264
ripple::tefTOO_BIG
@ tefTOO_BIG
Definition: TER.h:164
ripple::tecHAS_OBLIGATIONS
@ tecHAS_OBLIGATIONS
Definition: TER.h:282
ripple::tecNO_PERMISSION
@ tecNO_PERMISSION
Definition: TER.h:270
ripple::tefWRONG_PRIOR
@ tefWRONG_PRIOR
Definition: TER.h:156
ripple::temRIPPLE_EMPTY
@ temRIPPLE_EMPTY
Definition: TER.h:111
ripple::tecPATH_DRY
@ tecPATH_DRY
Definition: TER.h:259
ripple::telBAD_PUBLIC_KEY
@ telBAD_PUBLIC_KEY
Definition: TER.h:56
ripple::tecINSUFFICIENT_RESERVE
@ tecINSUFFICIENT_RESERVE
Definition: TER.h:272
ripple::terPRE_SEQ
@ terPRE_SEQ
Definition: TER.h:199
std::make_pair
T make_pair(T... args)
ripple::tefBAD_AUTH_MASTER
@ tefBAD_AUTH_MASTER
Definition: TER.h:162
ripple::tecNO_ENTRY
@ tecNO_ENTRY
Definition: TER.h:271
ripple::temBAD_PATH_LOOP
@ temBAD_PATH_LOOP
Definition: TER.h:95
ripple::temMALFORMED
@ temMALFORMED
Definition: TER.h:85
ripple::tefEXCEPTION
@ tefEXCEPTION
Definition: TER.h:152
ripple::telNO_DST_PARTIAL
@ telNO_DST_PARTIAL
Definition: TER.h:59
ripple::temBAD_TICK_SIZE
@ temBAD_TICK_SIZE
Definition: TER.h:116
ripple::tecNO_AUTH
@ tecNO_AUTH
Definition: TER.h:265
ripple::tecCLAIM
@ tecCLAIM
Definition: TER.h:246
ripple::temBAD_EXPIRATION
@ temBAD_EXPIRATION
Definition: TER.h:89
ripple::temBAD_SEND_XRP_LIMIT
@ temBAD_SEND_XRP_LIMIT
Definition: TER.h:97
ripple::telCAN_NOT_QUEUE_BALANCE
@ telCAN_NOT_QUEUE_BALANCE
Definition: TER.h:61
ripple::tecINSUF_RESERVE_OFFER
@ tecINSUF_RESERVE_OFFER
Definition: TER.h:254
unordered_map
ripple::tesSUCCESS
@ tesSUCCESS
Definition: TER.h:219
type_traits
ripple::temBAD_WEIGHT
@ temBAD_WEIGHT
Definition: TER.h:115
ripple::tecNO_DST
@ tecNO_DST
Definition: TER.h:255
ripple::temINVALID
@ temINVALID
Definition: TER.h:108
ripple::telCAN_NOT_QUEUE_BLOCKED
@ telCAN_NOT_QUEUE_BLOCKED
Definition: TER.h:63
ripple::tefBAD_SIGNATURE
@ tefBAD_SIGNATURE
Definition: TER.h:159
ripple::tecCRYPTOCONDITION_ERROR
@ tecCRYPTOCONDITION_ERROR
Definition: TER.h:277