Converts the measurement to the specified unit.
SDKs
- iOS 7.0+
- macOS 10.9+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 2.0+
- Xcode 8.3+
Framework
- Foundation
Declaration
mutating func convert(to otherUnit: UnitType)
Available when Unit Type conforms to Dimension.
Parameters
otherUnit
A unit of the same
Dimension
.