Class Amount.Builder

  • Enclosing class:
    Amount

    public static final class Amount.Builder
    extends java.lang.Object
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Amount build()  
      Amount.Builder currency​(java.lang.String currency)
      A 3-letter ISO 4217 currency code.
      Amount.Builder value​(long value)
      Quantity in the smallest unit of the specified currency.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • currency

        public Amount.Builder currency​(java.lang.String currency)
        A 3-letter ISO 4217 currency code.
      • value

        public Amount.Builder value​(long value)
        Quantity in the smallest unit of the specified currency.

        In USD this is cents, for example, $12.04 is 1204 and $0.99 is 99.

      • build

        public Amount build()