Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Things to change in v4 (maybe) #426

Open
sappenin opened this issue Jun 22, 2023 · 1 comment
Open

Things to change in v4 (maybe) #426

sappenin opened this issue Jun 22, 2023 · 1 comment

Comments

@sappenin
Copy link
Collaborator

sappenin commented Jun 22, 2023

  • Transaction Flags are technically optional, so the Java API should make them optional in each Transaction child class.
    • E.g., in Payment, the API should be Optional<PaymentFlags> flags() with the default implementation removed.
    • This is more idiomatically Java than the v3 solution, which was implemented via Allow for empty/omitted transaction flags #425.
    • Note that LedgerObject flags are not optional, so we need to make sure that classes like AccountRootObject do not make their flags Optional.
    • For Transaction objects, builder.build() should by default have an empty flags in it.
    • For LedgerObjects, builder.build() should by default have flags set to Flags.UNSET because these objects always have flags, but by default they're 0.
    • For all builders, we remove the concept of tfFullyCanonicalSig (e.g., here).
  • Consider making the default LedgerSpecifier in any request builder to be LedgerSpecifier.VALIDATED instead of LedgerSpecifier.CURRENT.
  • Remove Secp256k1.java which was deprecated as part of Fixes #446 (Consistent secp256k1 Curve) #447
  • Consider concrete subclasses of TransactionMetadata for NFTs (fields added here); Payments (delivered_amount); and metadata that shows up in all transactions.
  • Add an UnknownTransaction object that can take the place of a transaction that xrpl4j doesn't yet support. For example, loading ledgers (and transactions) from the Hooks devnet should not blow-up (but currently they would).
  • Implement: Add optional support for XRPL API v2 #481
  • Add overt input length checks into PublicKey constructors (similar to the constructors for PrivateKey)
  • Consider a new type of wrapper that enforces the number of bytes (e.g., PrivateKeyUnsignedByteArray) that gives a value, and a paddedValue, or similar? See Inconsistent Length of Private Key Byte Array in deriveKeyPair Method #486 for inspiration.
@sappenin
Copy link
Collaborator Author

Consider this list for any new API endpoints or breaking changes: https://github.com/XRPLF/rippled/issues?q=label%3A%22API+Change%22+is%3Aclosed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant