Changes in 2020 vs 2021 19 missing 12 changed
Flip API Versions →Missing in 2020 (only available in 2021)
Convert(Double, ForgeTypeId, ForgeTypeId)
ConvertFromInternalUnits(Double, ForgeTypeId)
ConvertToInternalUnits(Double, ForgeTypeId)
GetAllSpecs
GetAllUnits
GetDisplayUnitType(ForgeTypeId)
GetSpecTypeId(UnitType)
GetSymbolTypeId(UnitSymbolType)
GetTypeCatalogStringForSpec(ForgeTypeId)
GetTypeCatalogStringForUnit(ForgeTypeId)
GetUnitGroup(ForgeTypeId)
GetUnitSymbolType(ForgeTypeId)
GetUnitType(ForgeTypeId)
GetUnitTypeId(DisplayUnitType)
GetValidUnits(ForgeTypeId)
IsSpec(ForgeTypeId)
IsSymbol(ForgeTypeId)
IsUnit(ForgeTypeId)
IsValidUnit(ForgeTypeId, ForgeTypeId)
Changed members
UnitUtils.Convert(Double, DisplayUnitType, DisplayUnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `Convert(double, ForgeTypeId, ForgeTypeId)` overload instead.
| value | Double | The value to convert. |
| currentDisplayUnit | DisplayUnitType | The current display unit. |
| desiredDisplayUnit | DisplayUnitType | The desired display unit. |
UnitUtils.ConvertFromInternalUnits(Double, DisplayUnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `ConvertFromInternalUnits(double, ForgeTypeId)` overload instead.
| value | Double | The value to convert. |
| displayUnit | DisplayUnitType | The desired display unit. |
UnitUtils.ConvertToInternalUnits(Double, DisplayUnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `ConvertToInternalUnits(double, ForgeTypeId)` overload instead.
| value | Double | The value to convert. |
| displayUnit | DisplayUnitType | The value's display unit. |
UnitUtils.GetTypeCatalogString(UnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `GetTypeCatalogStringForSpec(ForgeTypeId)` method instead.
| unitType | UnitType | The unit type. |
| → returns | String | The type catalog string, or an empty string if the unit type cannot be used in type catalogs. |
UnitUtils.GetTypeCatalogString(DisplayUnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `GetTypeCatalogStringForUnit(ForgeTypeId)` method instead.
| displayUnit | DisplayUnitType | The display unit. |
| → returns | String | The type catalog string, or an empty string if the display unit cannot be used in type catalogs. |
UnitUtils.GetUnitGroup(UnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `GetUnitGroup(ForgeTypeId)` overload instead.
| unitType | UnitType | The unit type. |
UnitUtils.GetValidDisplayUnits(UnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `GetValidUnits(ForgeTypeId)` method instead.
| unitType | UnitType | The unit type. |
| → returns | IList | The valid display units. |
UnitUtils.GetValidDisplayUnits()
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `GetAllUnits()` method instead.
| → returns | IList | The valid display units. |
UnitUtils.GetValidUnitTypes()
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `GetAllSpecs()` method instead.
| → returns | IList | The valid unit types. |
UnitUtils.IsValidDisplayUnit(UnitType, DisplayUnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `IsValidUnit(ForgeTypeId, ForgeTypeId)` method instead.
| unitType | UnitType | The unit type. |
| displayUnit | DisplayUnitType | The display unit to check. |
| → returns | Boolean | True if the display unit is valid, false otherwise. |
UnitUtils.IsValidDisplayUnit(DisplayUnitType, DisplayUnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `IsUnit(ForgeTypeId)` method instead.
| displayUnitEnum | DisplayUnitType | The display unit to check. |
| displayUnit | DisplayUnitType | The display unit to check. |
| → returns | Boolean | True if the display unit is valid, false otherwise. |
UnitUtils.IsValidUnitType(UnitType, UnitType)
Became obsolete in 2021: This method is deprecated in Revit 2021 and may be removed in a future version of Revit. Please use the `IsSpec(ForgeTypeId)` method instead.
| unitTypeEnum | UnitType | The unit type to check. |
| unitType | UnitType | The unit type to check. |
| → returns | Boolean | True if the unit type is valid, false otherwise. |