Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- data class SingleEventMessage(
- private var initialValue: String = ""
- ) {
- var value: String = initialValue
- private set
- get() {
- if (initialValue.isEmpty())
- return ""
- if (initialValue.isNotEmpty() && field.isNotEmpty()) {
- val returnValue = field
- value = ""
- initialValue = ""
- return returnValue
- } else {
- return ""
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement