The FMPTransaction.Builder class is a builder for the FMPTransaction class.
class Builder
| Method | Description |
| id(_:) | Save transaction identifier to variable. func id(_ id: String) -> Builder Parameters:
|
| resource(_:) | Save transaction resource to variable. func resource(_ resource: FMPResource) -> Builder Parameters:
|
| build() | Build an instance of the FMPTransaction class. It returns the object of the FMPTransaction type. func build() -> FMPTransaction |
Build an instance of the FMPTransaction class:
// Build an instance of the FMPResource class. For details see examples for FMPResource.Builder.
let resource: FNPResource = fmp.resource.build()
// Build an instance of the FMPTransaction class
let transaction: FMPTransaction = fmp.transaction
.id("id") // By default ""
.resource(resource) // By default nil
.build()
See also: