withDataModelOrNull Function
Modifiers:
final Access the DataModel if available, or null otherwise.
Example:
val result = withDataModelOrNull { dm ->
// Operations that may fail gracefully
}
inline fun <R> withDataModelOrNull(block: (DataModel) -> R): R?
A lambda that receives the DataModel.
The value returned by the block, or null if no DataModel is set.