| Modifier and Type | Method and Description |
|---|---|
Cost.Builder |
amount(Float amount)
Initializes the value for the
amount attribute. |
Cost |
build()
Builds a new
Cost. |
Cost.Builder |
currency(String currency)
Initializes the value for the
currency attribute. |
Cost.Builder |
from(Cost instance)
Fill a builder with attribute values from the provided
Cost instance. |
Cost.Builder |
unit(String unit)
Initializes the value for the
unit attribute. |
public final Cost.Builder from(Cost instance)
Cost instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final Cost.Builder amount(Float amount)
amount attribute.amount - The value for amountthis builder for use in a chained invocationpublic final Cost.Builder currency(String currency)
currency attribute.currency - The value for currencythis builder for use in a chained invocationpublic final Cost.Builder unit(String unit)
unit attribute.unit - The value for unitthis builder for use in a chained invocationpublic Cost build()
Cost.IllegalStateException - if any required attributes are missingCopyright © 2020. All rights reserved.