Join Slack
Powered by
Hey I was wondering if it was at all possible to s...
# getting-started
t
Tech
08/19/2023, 3:23 AM
Hey I was wondering if it was at all possible to send a warning to the IDE if a function parameter is below 1.
h
hho
08/19/2023, 2:14 PM
You can set a conditional breakpoint in the debugger, like so:
s
Stephan Schröder
08/19/2023, 2:28 PM
• you could use an Observable to at least log a warning, when an value is below 1 (
https://kotlinlang.org/docs/delegated-properties.html#observable-properties
) • you could also use a vetoable, to make sure the value can never be set below 1 and log it if some process tries to do it
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.properties/-delegates/vetoable.html
4
Views
Open in Slack
Previous
Next