W3cubDocs

/Kotlin

returnsNotNull

Platform and version requirements: JVM (1.0), JS (1.0), Native (1.0)
abstract fun returnsNotNull(): ReturnsNotNull

Describes a situation when a function returns normally with any value that is not null.

Use SimpleEffect.implies function to describe a conditional effect that happens in such case.

© 2010–2019 JetBrains s.r.o.
Licensed under the Apache License, Version 2.0.
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.contracts/-contract-builder/returns-not-null.html