Instance Method
parse(_:)
iOS 15.0+
iPadOS 15.0+
Mac Catalyst 15.0+
macOS 12.0+
tvOS 15.0+
watchOS 8.0+
Parses a value, using this strategy.
func parse(_ value: Self.ParseInput) throws -> Self.ParseOutput
Parameters
valueA value whose type matches the strategy’s
ParseInputtype.
Return Value
A parsed value of the type declared by ParseOutput.
Discussion
This method throws an error if the parse strategy can’t parse value.